Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...

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 / rakesh ranjan

#include<conio.h>
#include<stdio.h>
void main()
{
char str[20],i;
printf("enter your name:");
scanf("%s",str);
for(i=0;str[i]!='\0';i++)
{
if(str[i]<=91)
str[i]+=32;
else
str[i]-=32;
printf("%c",str[i]) ;
}
getch();
}

Is This Answer Correct ?    2 Yes 1 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

When should the const modifier be used?

1117


What is a static variable in c?

1129


What is the best way to store flag values in a program?

1081


Can you return null in c?

1169


Is it acceptable to declare/define a variable in a c header?

1126


What are the main characteristics of c language describe the structure of ac program?

1212


How many levels of indirection in pointers can you have in a single declaration?

1089


What is variables in c?

1054


How can I invoke another program (a standalone executable, or an operating system command) from within a c program?

1214


Can we replace the struct function in tree syntax with a union?

1310


regarding pointers concept

2040


What is the scope of an external variable in c?

1050


What are pointers?

1111


How can I get back to the interactive keyboard if stdin is redirected?

1190


Is this program statement valid? INT = 10.50;

1155