So I am just playing around, changing things to see what happens when I do (I learn this way). I know this isn't how one should do it, but I wondered how I could get this to work. This is my third or so try at what I want. I am hoping to be able to use ofstream.write to write a string to a file one letter at a time.
is basically (as far as the result in the text file) the same as what I did, i.e.,
constchar * c = &S[0];
The result is the same, 5 copies of the word "Funky" in the text file. The problem (AFAIK) is that output.write wants a const * char, so in order to do each letter one at a time, I need each element of c to be a const * char. If I am wrong, please tell me how! Thanks again.
I figured it out. Remember I was just playing around trying to learn by doing, so as expected, this isn't pretty. If anyone knows of a more elegant way to start with a string object and write to a file using "write" one letter at a time, please post it here. Thanks.