C Exercises: Display firstname, lastname and year of birth sequentially
7. Display Personal Information
Write a program in C that reads a forename, surname and year of birth and displays the names and the year one after another sequentially.
Pictorial Presentation:

Sample Solution:
C Code:
Sample Output:
Input your firstname: Tom Input your lastname: Davis Input your year of birth: 1982 Tom Davis 1982
Flowchart:

For more Practice: Solve these Related Problems:
- Write a C program to read a first name, last name, and year of birth and then output them in reverse order.
- Write a C program to read a person's forename, surname, and year of birth, calculate the current age, and display a formatted message.
- Write a C program to input a forename, surname, and year of birth, then display only the initials followed by the birth year.
- Write a C program to store personal information in a structure and then print the data in a specified formatted sequence.
C Programming Code Editor:
Previous: Write a program in C that takes minutes as input, and display the total number of hours and minutes.
Next: Write a program in C to calculate the sum of three numbers with getting input in one line separated by a comma.
What is the difficulty level of this exercise?
Based on 68 votes, average difficulty level of this exercise is Hard
.
Test your Programming skills with w3resource's quiz.