write a c program for print your name .but,your name may be small
letter mean print a capital letter or your name may be capital
letter mean print a small letter .example
\\enter ur name :
sankar
The name is: SANKAR
(or)
enter your name:SAnkar
The name is:saNKAR

Answer Posted / ganesh

char s[15];int n,i;
scanf("%s",s,printf("give a name:"));
for(i=0;i<strlen(s);i++)
{
if(s[i]==tolower(s[i]))
putchar(toupper(s[i]));
else
putchar(tolower(s[i]));
}

Is This Answer Correct ?    13 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What are different types of variables in c?

566


Why is it that not all header files are declared in every C program?

676


largest Of three Number using without if condition?

1003


What are operators in c?

575


What is the easiest sorting method to use?

632






What is %d used for?

580


Explain what are multidimensional arrays?

596


Why is c faster?

588


What is the difference between procedural and declarative language?

643


Explain how can I manipulate strings of multibyte characters?

778


What is pointer and structure in c?

565


What do mean by network ?

652


A c program to display count values from 0 to 100 and flash each digit for a secong.reset the counter after it reaches 100.use for loop,. pls guys hepl me.. :(

1731


What is boolean in c?

603


What does int main () mean?

543