|
-
Nov 22nd, 2002, 05:01 AM
#1
Thread Starter
Junior Member
Diff- \r and \n
What is the difference between carriage return and newline?
-
Nov 22nd, 2002, 05:08 AM
#2
Addicted Member
\n is in fact the combination of carriage return and line feed; so that you go to the beginning og the next line
-
Nov 22nd, 2002, 06:14 AM
#3
Thread Starter
Junior Member
Thanks but then what is the function of \r - carriage return?
Printf ( " sss \r ddd");
This line prints just ddd. why?
-
Nov 22nd, 2002, 06:24 AM
#4
Addicted Member
The carriage return will return the cursor to the leftmost position without going to the next line. Obviously your sss is overwritten by ddd
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|