code or use...
Line feed characters in the file:
Linux, unix: \ r \ n
Windows: \ n
Mac OS: \ r
Corresponding:
\ N LF or 0x0A (10) in ASCII)
\ R CR or 0x0D (13) in ASCII)
\ T horizontal tab-0x09 (9) in HT or ASCII)
\ Backslash
\ $ Circle character
\ "Double quotation marks
\ 'Single quotes
Reasons for their origins and divergence:
The concepts of carriage return and line feed are different.
Before the computer appeared, there was a kind of device called Teletype Model 33, which can contain
First, let's talk about the differences between \ r and \ n.The origins and differences between Carriage Return and Line Feed.Before the computer appeared, there was a kind of thing called Teletype Model 33, which also came from the tty concept in Linux/Unix. It can contain 10 characters per second. But there is a problem, that is, when a line breaks a line, it takes 0.2 seconds, just two characters. If a new character is passed in the 0.2 s, the character will be lost.As a result, the developer
Corresponding:
\ N LF or 0x0A (10) in ASCII)
\ R CR or 0x0D (13) in ASCII)
\ T horizontal tab-0x09 (9) in HT or ASCII)
\ Backslash
\ $ Circle character
\ "Double quotation marks
\ 'Single quotes
Reasons for their origins and divergence:
The concepts of carriage return and line feed are different.
Before the computer appeared, there was a kind of device called Teletype Model 33, which can contain 10 characters per second. But there is a problem, that is, when a line breaks a line, it takes 0
to display the effect on the page, you need to convert it to HTML code or use...
Line Feed characters in the file:
Linux, unix: \ r \ n
Windows: \ n
Mac OS: \ r
Corresponding:
\ N LF or 0x0A (10) in ASCII)
\ R CR or 0x0D (13) in ASCII)
\ T horizontal tab-0x09 (9) in HT or ASCII)
\ Backslash
\ $ Circle character
\ "Double quotation marks
\ 'Single quotes
Reasons for their origins and divergence:
The concepts of carriage return and line feed are different.
Before the computer appeared, ther
The origins and differences between carriage return and line feed.
Not on the computerBefore the appearance, there was a teletype Model33. The tty concept in Linux/Unix also comes from this). It can contain 10 characters per second. However, the problem is that it takes 0.2 seconds to finish a line breakIt can be two characters long. If a new character is passed in the 0.2 s, the character will be lost.
As a result, the developers thought of a way to solve this problem, that is, adding two e
passed in the 0.2 s, the character will be lost.
As a result, the developers thought of a way to solve this problem, that is, adding two end characters after each line. One is "enter", which tells the typewriter to position the print head on the left boundary, and the other is "line feed", which tells the typewriter to move the paper down one line.
This is the source of "line feed" and "Carriage Return". T
Line feed(\ N)That is, move the cursor down a line but not move it to the beginning of this line. Press ENTER(\ R)Is to return to the beginning of the current row but not move down a row.
Press enter to execute\ N \ rIn this way, we can see the general meaning of the carriage return, so we can use a hexadecimal file to view a text, and we will find it at the end of the line"\ N \ r".
Line break during program debugging\ R \ n.
Tab is a tab, that is"\ T"To reserve the display width of 8 charac
Some time ago, I transplanted a program in Windows to VxWorks. Because the original program needs to read the configuration file
Put them together in nor flash, so it's hard to handle compilation errors. When a program is run, an error occurs and debugging is performed,
I found all the information I read was wrong !! No, let's take a closer look. The fopen string is like this: "First Line
\ R \ nsecond line \ r \ n... ", and then read it in Vs, but it is like this:" First line \ nsecond
Line \ n
problem, that is, when a line breaks a line, it takes 0.2 seconds, just two characters. If a new character is passed in the 0.2 s, the character will be lost.
As a result, the developers thought of a way to solve this problem, that is, adding two end characters after each line. One is "enter", which tells the typewriter to position the print head on the left boundary, and the other is "line feed", which tells the
First, let's talk about the differences between \ r and \ n.The origins and differences between Carriage Return and Line Feed.Before the computer appeared, there was a kind of thing called Teletype Model 33, which also came from the tty concept in Linux/Unix. It can contain 10 characters per second. But there is a problem, that is, when a line breaks a line, it takes 0.2 seconds, just two characters. If a new character is passed in the 0.2 s, the character will be lost.
As a result, the develop
Today, I have finally figured out the origins and differences between carriage return and line feed.Before the computer appeared, there was a kind of device called teletype model 33, which can contain 10 characters per second. But there is a problem, that is, when a line breaks a line, it takes 0.2 seconds, just two characters. If a new character is passed in the 0.2 s, the character will be lost.As a result, the developers thought of a way to solve this problem, that is, adding two end characte
Carriage Return and line feed
Press enter \ r, line feed \ n
History
The origins and differences between carriage return and line feed.
Before the computer appeared, there was a kind of device called teletype model 33, which can contain 10 characters per second. But there is a problem, that is, when a line breaks a line, it takes 0.2 seconds, just two characters. If a new character is passed in the 0.2 s, the character will be lost.
As a result, the developers thought of a w
to:nbsp; nbsp; n LF or 0x0a (a) nbsp; R CR or ASCII in 0x0d (a) nbsp; t Horizontal tab-HT or ASCII 0x09 (9) nbsp; backslash nbsp; $ dollar break nbsp; "double quotes nbsp; ' single quotes nbsp; nbsp;" about their origins and cause differences in scale original by:nbsp; nbsp; "Enter" (Car Riage return) and "line feed" the two concepts of the origins and differences. nbsp; Before the computer appeared, there was a gadget called the Teletype Model 33, which could be 10 characters per second. But i
\ ' Single quotes
About their origins and causes differences in the scale of the original by:
The origins and differences between the two concepts of "enter" (carriage return) and "line feed".
Before the computer appeared, there was a device called the teletype Model 33, which could play 10 characters per second. But it has a problem, that is, after a line of line change, to use 0.2 seconds, just can hit two characters. If there are new characters coming in this 0.2 seconds, the character wil
trouble. In fact, this is not to blame windows. \r\nThe history of use can be traced back to the distant 19th century. The typewriter, which was invented at that time, was a solid cylinder + a chrysanthemum-like font. The paper is firmly fastened to the surface of the cylinder. When we press a letter, the mechanical device "fly" to the paper, while the ribbon before the cylinder rises, hard to print, so th
Carriage return and line break 1. Meaning OriginEnter: Carriage return. Carriage, transport, conveying, train carriages, carriages.NewLine: Line Feed. The Feed, in its original sense, represents an interface used to receive updates from information sources.The meaning of the line is very clear, but why is called carriage return, enter the meaning of what is.OK, let's take a look at their origins.Before the computer appeared, there was a telex typewriter
of rice was to "salute Apple, learn from Xiaomi, and be in line with Meizu"."The truth About cell phone naming rules"Although it is called S, Note, but the name of Apple Samsung has a special meaning. For example, "s" in iphone4s refers to "Siri", while the 5s "s" is the meaning of "sensor", implying that since the beginning of 5s Apple will be equipped with fingerprint recognition function. Samsung's "note", as its name implies, is the meaning of "notes". When Samsung launched the note, it was
return", which tells the typewriter to position the print head at the left edge, and the other is called "line-wrapping", telling the typewriter to move the paper down one line.
This is the "line" and "return" of the history, from their English name can also be seen in one or two.
Later, the computer was invented, and the two concepts were also on the computer.
Difference between line breaks in Linux and Windows
The line breaks for Linux are not wrapped in Windows Notepad or appear as a result of line break differences in Linux and Windows.
First look at the return sign and the line break symbol to produce the background
The origins and differences between the two concepts of "enter" (carriage return) and "line feed".
Before the computer appeared, there was a device called the teletype Model 33, which could play 10 characters per second. But it has
file, the disk is not directly written, but the buffer is written first. Data is written to the disk only when "the buffer is full" or "close the file;It seems that no buffer can be set. In this case, low-level I/O functions are used to directly operate the disk, which is slow. It is not a standard function and is not suitable for cross-platform operations.3. Text and binary modes:When fopen is enabled, you can specify the file opening mode. "T" indicates the text mode, and "B" indicates the bi
The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion;
products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the
content of the page makes you feel confusing, please write us an email, we will handle the problem
within 5 days after receiving your email.
If you find any instances of plagiarism from the community, please send an email to:
info-contact@alibabacloud.com
and provide relevant evidence. A staff member will contact you within 5 working days.