But all it gave me was this, and I'm trying to get it to output the "a" with the other letters.
b c d e f
B c d e f
B c d e f
B C d e f
B C d e f
B C D e f
B C D e f
B C D E f
B C D E f
B C D E F
If someone could guide me in the right direction that would be much appreciated.
In that line of code it just calling the file object and putting it in a variable or placeholder then I'm getting it by calling it with a get line so I can output it out.
My ideal answer that I am supposed to be getting is "A B C D E F"
In that line of code it just calling the file object and putting it in a variable or placeholder then I'm getting it by calling it with a get line so I can output it out.
infile >> upquoteLine; extracts a space-delimited token from the stream represented by infile into the string upquoteLine.
getline(infile, upquoteLine); extracts the rest of the line into the string upquoteLine replacing the token extracted earlier.
Okay so I took out infile >> upquoteLine; and it just gave me a loop that outputs:
A b c d e f
A b c d e f
A B c d e f
A B c d e f
A B C d e f
A B C d e f
A B C D e f
A B C D e f
A B C D E f
A B C D E f
A B C D E F
but when i take out getline(infile, upquoteLine); it outputs:
A
is there any way to fix both? or whichever one is convenient
Wow, thank you haha. When I rearranged the code I literally screamed of joy. Now I just need to find out how to reverse it but I can probably figure it out myself. Thank You Cire, ne555