#include<stdio.h>
/***
int main()
{
char a;
printf("enter a character:");
while(1){
scanf("%c",&a);
if(a==48)
break;
if(a>=65&&a<=90)
printf("%c ",a+32);
}
return 0;
}
***/
#include<stdio.h>
int main(){
char str[100];
int i;
printf("Enter any string:\n");
scanf("%s",str);
printf("\nThe string is:%s\n",str);
for(i=0;i<strlen(str);i++){
if(str[i]>=65&&str[i]<=90)
str[i]=str[i]+32;
}
printf("\nThe Lower case string is:%s\n",str);
return 0;
}
No comments:
Post a Comment