Advertisement
jbonanno

programTest.py

Jun 27th, 2017
81
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Python 0.65 KB | None | 0 0
  1. # This program asks for name and age
  2.  
  3. #The program welcomes you and asks your name
  4. print ('Hi and welcome to the program!')
  5. print ( 'What is your name?')
  6. Name = input()
  7.  
  8. #The program greets you by name.
  9. print ('Nice to meet you' + Name)
  10. #The program prints out your name length.
  11. print ('The length of your name is:')
  12. print(len(Name))
  13.  
  14. #The program asks for your age
  15. age = int(input("What is your age?: "))
  16. #Using the user input for age, the program determines what section the program will take you to.
  17. if age < 12:
  18.     print ('This program will take you to the kids section')
  19. else:
  20.     print ('This program will take you to the regular user section')
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement