C program to check whether given alphabet is in Upper case or lowercase.

#include<stdio.h>
#include<conio.h>
void main() {
char ch;
clrscr();
printf("Enter an alphabet\n");
scanf("%c",&ch);
if (ch>=65&&ch<=90) 
printf("%c is in Upper Case or Capital Letter\n",ch);
else {
if (ch>=97&&ch<=122) 
printf("%c is Lower Case or Small Letter\n",ch);
else 
printf("%c is not an alphabet\n",ch);
}
getch();
}

Comments

Popular posts from this blog

C Language Topics in Hindi and English

C language IMP Questions for BSc/BA/BCom/BCA/BE/BTech/MSc/MCA (CS/IT) I year students