I'm working on an assignment and I've run into a small problem. Our teacher wants us to read a line from a file containing three things we need sperated by a whitespace. I'm trying to figure out the cleanest way to read the line and then break it into the three parts, add each seperate element to an array and a textbox control.
so for example, the first readline would give:
Dustin 90 A
I only need to do this five times, so I know I'm using two nested loops, the first set to a 5 count, the second to a three count, but I really don't want to check each individual char. Any help?
I know what to do once I get it broken up, the three values will be sent to their respective textbox control and I can populate the respective arrays as well, but this is going to be a pain if I have to read every char looking for a whitespace. :|