C program to print UPPER CASE into lower case.


C program
C PROGRAM 

C program to print UPPER CASE  into lower case

#include <stdio.h>
#include<conio.h>
#include<string.h>
void main()
{
    char str[25],i;
    printf("Enter the string\n");
    scanf("%s",&str);
    for(i=0; i<=strlen(str); i++)
    {
        if(str[i]>=65&&str[i]<=90)
            str[i]=str[i]+32;
    }
    printf("lower case string is:%s",str);
    return 0;
}

OUTPUT:

enter the string
MANIKANDAN
lower case string is:manikandan
[Process completed (code 33) - press Enter]

No comments:

Post a Comment




Copyright Ⓒ 2022 | Mechpedia | All Right Reserved.