Advertisement
182days

Functions

May 10th, 2016
145
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Python 0.47 KB | None | 0 0
  1. #basic function application
  2. def func1():
  3.     print("This is function 1 output")
  4. def func2():
  5.     print("This is function 2 output")
  6. def func3():
  7.     print("This is function 3 output")
  8. def func4():
  9.     print("This is function 4 output")
  10.  
  11. while True:
  12.     choice = input("What function would you like to run?")
  13.     if choice == "1":
  14.         func1()
  15.     if choice == "2":
  16.         func2()
  17.     if choice == "3":
  18.         func3()
  19.     if choice == "4":
  20.         func4()
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement