prev


ASCII value

37. Converts uppercase to Lowercase (16.7.2009)

/*
Program# 37
date : 25-12-2008
Convert uppercase to Lowercase
*/

#include <stdio.h>
main(){
char a;
printf("\nEnter a Uppercase alphabet :");
scanf("%c",&a);
if(a>=65 && a<=90){
a=a+32;
printf("\nLowercase letter is %c \n",a);
}
else
printf("\n%c is Not uppercase letter\n",a);
}

output:
To compile the program, run the gcc command,

$ gcc p37.c

Now the executable file is stored as a.out, to run
the program,

$ ./a.out

Enter a Uppercase alphabet :H

Lowercase letter is h
$
next
blog comments powered by Disqus