What's the most idiomatic way to loop over input one line at at time, like the C code while ((s = fgets(...)) != NULL) { ... } Many TIA, Mark -- Mark Harrison Pixar Animation Studios