Python/Curses 200 194 182 121
Assumes file is in working directory and file name is stored in variable f
from curses import*;import time;s=initscr();F=file.read(file(f)).split('\n');y=0
while 1:
for i in F:
s.addstr(y,0,i);s.refresh();y+=1
if i=='':y=0;s.clear();time.sleep(1)
Or, down to 121 when not using curses
import time,os;F=file.read(file(f)).split('\n')
while 1:
for i in F:
print i
if i=='':time.sleep(1);os.system('cls')
Note: replace 'cls'
with 'clear'
if no a unix based system, adding 2 chrs.
ctl+C
to quit
Edit: Changed the filename method, now uses a variable (-6chrs)
Edit: Changed the for
to iterate through the list F
- Thanks ace (-12chrs)