PDA

View Full Version : characters in file



LackeyLad
17th December 2004, 04:33 PM
so...

apearently iwhen i read characters from a data file in c++ they skip over the white space?

pseudo code:


read in char from file
is it ' ' (space)


but it skips all that automatically.

how do i read chars from a file including the spaces, tabs, newlines, etc??

LackeyLad
17th December 2004, 04:51 PM
nevermind

ifstream >> overloaded doesnt read whitespace, where .get(char &) does.

thanks