5 Topics
|
|
std::endl vs \n Are any particular one which should be used at specific times? I understand endl flushes the stream (although i'm not 100% what this means) while \n is simply a newline. |
|
Hello! I am having some trouble with reading data for a list. If at the end of the file there is a new line character, this function reads the last set of data again, and then exits the loop. The addElem function works fine, I tested it separately. As there … |
|
I am currently writing a program that can calculate the number of total seconds in a user given number of hours, minutes, and seconds (in that order in hh:mm:ss format hh, mm, and ss being any number from 0-99). I'm not really worried for checking for errors in user input, … |
|
I have to write an extension of basic_stringstream class, and I'm facing some difficulties with endl() function. Here is my code [CODE] class Logger: public basic_stringstream<TCHAR> { public: Logger(); }; inline Logger& __cdecl endl(Logger& _Ostr) { // Original code in ostream _Ostr.put(_T('\n')); _Ostr.flush(); return (_Ostr); } int main() { Logger … |
|
Hi! I just upgraded to win 7 64 bit. I have tryed it both on cygwin compiler and MinGW compiler (toolchain) Working on eclipse. My code works perfect in Linux/ubuntu environment but running in win 7 environment I have the following problem. My last cin does not work. The input … |
The End.