Advertisement
Guest User

Untitled

a guest
Jun 16th, 2017
68
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. #include <stdio.h>
  2.  
  3. int main()
  4. {
  5.     char name[10] = {'\0'};
  6.     char gender[10] = {'\0'};
  7.     char age[10] = {'\0'};
  8.     char city[10] = {'\0'};
  9.     char town[10] = {'\0'};
  10.     char occupation[10] = {'\0'};
  11.     char accept[6] = {'\0'};
  12.     char correct[10] = {'\0'};
  13.    
  14.     printf("What is your name?");
  15.     scanf("%s", name);
  16.    
  17.     printf("\nWhat is your gender?");
  18.     scanf("%s", gender);
  19.    
  20.     printf("\nWhat age are you?");
  21.     scanf("%s", age);
  22.    
  23.     printf("\nPlease state your city of birth.");
  24.     scanf("%s", city);
  25.    
  26.     printf("\nName your town of residence.");
  27.     scanf("%s", town);
  28.    
  29.     printf("\nWhat is your current occupation?");
  30.     scanf("%s", occupation);
  31.    
  32.     printf("\nPlease tpe accept");
  33.     scanf("%s", accept);
  34.    
  35.     printf("\n\nYour name is %s.\nYou are %s .\nYou are %s years old.\nYou were born in %s city.\nYou are living in %s.\nYour current occupation is %s \n\n Is this information correct? If so please type Correct.", name, gender, age, city, town, occupation);
  36.     scanf("%s", correct);
  37.    
  38.     printf("\nYour information is %s. Thank you for submiting your information.", correct);
  39.     getchar();
  40.     getchar();
  41.  
  42.    
  43. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement