C examples for Data Type:char
Enter an ASCII code value, such as 66, and then prints the character having that ASCII code.
#include <stdio.h> int main(void) { int ascii; //from w w w . j a v a 2s . com printf("Enter an ASCII code: "); scanf("%d", &ascii); printf("%d is the ASCII code for %c.\n", ascii, ascii); return 0; }