More often than not, infinite loops are created by programming errors and are quickly dealt with. In sympathy for this highly persecuted group of programs, a safe haven has been created on
retro code. The two infinite loops below are highly optimized examples. In fact, the actual loops are only 1 byte long!
Z80 Infinite Loop ld hl, HERE
HERE:jp (hl)
8080 Infinite Loop lxi h, HERE
HERE:pchl
Corewar Infinite Loop jmp #0, <-5
In
Corewar, the infinite loop finds its niche destroying small mobile programs called imps!
If you know any infinite loops in need of shelter, please post them in the comments below.