in reply to
Re: Help to split
in thread Help to split
It's usually a better practice when asking for help here to explain what you've tried, and how it's failing, but not to dictate what tools a proper solution should employ.
He may not have explicitly stated it, but this is clearly a homework assignment. The "solve by using split
one or more times" requirement is part of the assignment. Even if he knew other ways to do it, the instructor has declared them to be out of bounds.
Beyond that, he's also provided his source code in the question, which qualifies as "explain[ing] what you've tried" in my book. The only thing missing from the question is a statement of how it fails, although I expect that was obvious to most experienced monks pretty quickly (as CountZero said, he forgot to read from the file after opening it).