Ques:-11) Any character is entered through the keyboard, write a program to determine whether the character entered is a capital letter, a small case letter, a digit or a special symbol. The following table shows the range of ASCII values for various characters.

				
					#include<stdio.h>
#include<conio.h>
void main()
{	
char num;
clrscr();
printf("enter the number");
scanf("%c",&num);
if (num>=65 && num<=90)
printf("CAPITAL LETTER");
else if(num>=97 && num<=122)
printf("SMALL LETTER");
else if(num>=48 && num<=59)
printf("number 0-9");
else
printf("special symbols");
getch();
}


				
			

Out Put

				
					Enter the number: 2
number 0-9
				
			
Scroll to Top