The following code prints 5 lines why is it not 4?
<?php
header('Content-Type: text/plain');
$myString = "line1\nline2\nline3\nline4\n";
$myArray = explode("\n", $myString);
while(list($lineNum, $line) = each($myArray))
{
echo ($lineNum+1) . ": $line\n";
}
?>