This is a real world task which can be solved in a couple of lines. Which makes me think that you guys can do it in about half a line!
The simple version of the task is to verify that each line of a file is the insertion of one character somewhere (maybe at the start or the end) into the prior line. So <<< 1 12 132 x132 >>> would be accepted, but <<< 1 12 132 alien132 >>> would not be accepted. If that's too easy, or too short, the more advanced version of the task is for each line to print which character has been inserted in which position for each line. There's a lot of flexibility on how the verification result is reported to the user, so you may, within sensible limits, do whatever's best. An error return value, or printing a Y or N, or 1 or 0, or the line number on which it fails, or anything like that would be fine. Similarly, whether you start counting at 0 or 1, I don't care, I can cope with both. This is for a little bit of mathematical research I'm doing (so the lines in the file will actually just be big numbers), and I will happily credit the winner when I announce the results of the research. That'll be weeks away, but I wouldn't want anyone to waste more than a short while on this task. Phil () ASCII ribbon campaign () Hopeless ribbon campaign /\ against HTML mail /\ against gratuitous bloodshed [stolen with permission from Daniel B. Cristofani] ____________________________________________________________________________________ No need to miss a message. Get email on-the-go with Yahoo! Mail for Mobile. Get started. http://mobile.yahoo.com/mail