Site icon Pharmawiki.in

[C program code] Demonstration of Backslash Characters or Escape sequences

First year of B- Pharmacy has a subject Remedial Maths & Computers in which C language is the important topic. This is one of the important questions of it “[C program code] Demonstration of Backslash Characters or Escape sequences”

Backslash or escape characters

 

/*Demonstration of Backslash Characters or
Escape sequences
*/
#include<stdio.h>
main  ()
{int i;
clrscr();
printf(“this is formfeed\t\t Example\f  (\\f)\n”);
getch();
printf(“this is audible alert\t\t Example\a  (\\a)\n”);
getch();
printf(“this is Backspace\t\t Example\b  (\\b)\n”);
getch();
printf(“this is NULL\t\t Exam\n\0ple (\\0)\n”);
getch();
printf(“this is newline\t\t \n Example (\\n)\n”);
getch();
printf(“this is horizontal tab\t\t Exam\tple  (\\t)\n”);
getch();
printf(“this is Vertical tab\t\t Example\v  (\\v)\n”);
getch();
printf(“this is formfeed\t\t Example\f  (\\f)\n”);
getch();
printf(“this is carriage return\t\t \rExample(\\r)”);
getch();
}

[/code]

Exit mobile version