I have to read in an undetermined amount of 5 character strings from the keyboard, all entered in one line. Valid input for example, with each example on a new line:
Code:
BBBBG YPZAA ABCD6
BBBBG WANAB REWWW ZZAA0 PPP14
AAAAC BBBBE CCCC5 ABCD4 QQQ3R ERFG8
AAAAB CCC14 QQQQD ZZZZ4 ZE_B12
AAAAC BBBBE CCCC5 ABCD4 QQQ3R ERFG8 PPP14 REWD2
I need to get each 5 character string from the input and store them all into an array. I do not know how to do this.
For testing I just faked it, using "cin >>" five times. I need to expand tha to accept as few as 1 and as many as 20.
Thanks for your time and help.