![]() One is that code that assumes '\n' is LF could fail. There would be some potential problems with the second approach. Treat '\n' as the ASCII CR character, which requires no conversion on input or output.Treat '\n' as the ASCII LF character, and convert it to and from CR on output to and input from text streams (similar to the conversion between LF and CR-LF on Windows systems) or. ![]() There are (at least) two possible approaches that could have been taken: The question is, what are the values of the character constants '\n' and '\r' in C and C compilers for Mac OS releases prior to OS X? Mac OS 10, unlike earlier releases, is UNIX-like, and uses the ASCII LF (line feed) character, value decimal 10, to mark the end of a line. In versions of Mac OS up to version 9, the standard representation for text files used an ASCII CR (carriage return) character, value decimal 13, to mark the end of a line.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |