retoure a la ligne C
To return to a new line in C, you can use the escape sequence \n
. The escape sequence \n
is a special character that represents a new line. When it is encountered in a string, it causes the cursor to move to the beginning of the next line.
Here is an example:
#include <stdio.h>
int main() {
printf("This is the first line.\n");
printf("This is the second line.\n");
printf("This is the third line.\n");
return 0;
}
In this example, the printf
function is used to print three lines of text. The \n
escape sequence is used at the end of each line to indicate that a new line should start.
When you run this program, the output will be:
This is the first line.
This is the second line.
This is the third line.
Each printf
statement is printed on a new line because of the \n
escape sequence.