C Escape Sequence

A sequence of characters starting with backslash ( \ ) that performs a specified function, which is already defined by C, is called as an escape sequence in C. It is named so as it doesn’t represent itself as a character, when it is used inside a string.

Some of the C Escape Sequence are listed below.

\aAlarm or Beep
\rCarriage Return
\”Double Quote
\fForm Feed
\xhhHexadecimal Number
\nNew Line
\nnnOctal Number
\?Question Mark
\’Single Quote
\tTab (Horizontal)
\vVertical Tab



#include <stdio.h>
void main()
printf ("\tI love my INDIA.\vINDIA is my Country.\nMy Country is my Identity.");


I love my INDIA.                                                                                                             
                        INDIA is my Country.                                                                                         
My Country is my Identity.
Content Protection by DMCA.com
Please Share