WAP to accept first name,middle name & last name of a
student display its initials?
Answer Posted / ankush
#include<stdio.h>
#include<conio.h>
void main()
{
char fnm[20],snm[10],lnm[10];
clrscr();
printf("Enter student First Name: ");
gets(fnm);
printf("Enter student Middle Name: ");
gets(snm);
printf("Enter student Last Name: ");
gets(lnm);
printf("\nThe Name is: ");
printf("%s %s %s",fnm,snm,lnm);
getch();
}
Is This Answer Correct ? | 12 Yes | 7 No |
Post New Answer View All Answers
What is the sizeof () operator?
What are shell structures used for?
State two uses of pointers in C?
Explain Function Pointer?
a number whose only prime factors are 2,3,5, and 7 is call humble number,,write a program to find and display the nth element in this sequence.. sample input : 2,3,4,11,12,13, and 100.. sample output : the 2nd humble number is 2,the 3rd humble number is 3,the 4th humble number is ,the 11th humble number is 12, the 12th humble number is 14, the 13th humble number is 15, the 100th humble number is 450.
How is a pointer variable declared?
Is stack a keyword in c?
Explain data types & how many data types supported by c?
Why pointers are used in c?
What is the use of ?
What is wrong with this initialization?
How many parameters should a function have?
What are the 5 types of inheritance in c ++?
How do you define structure?
#include