Python    
while 1:
    line = sys.stdin.readline()
    if not line:
        break