Advertisement
Guest User

Untitled

a guest
Nov 24th, 2017
44
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Python 12.41 KB | None | 0 0
  1. import sys
  2.  
  3. def support():
  4.     #keeps going round until a valid response is given
  5.     while(True):
  6.         support = str(input("Do you need support with Maths or English "))
  7.    
  8.         if support == "maths" or support == "Maths":
  9.             math()
  10.         elif support == "english" or support == "English":
  11.             english()
  12.         else:
  13.             print("Please enter a valid response")
  14.    
  15. def math():
  16.     #math fucntion
  17.     while(True):
  18.         mathhelp = str(input("Ok, is there anything in particular you need help with in Maths? "))
  19.         if mathhelp == "excel" or mathhelp == "Excel":
  20.             daycheck()
  21.         elif mathhelp == "latex" or mathhelp == "LATEX":
  22.             daycheck2()
  23.         elif mathhelp == "matlab" or mathhelp == "MATLAB":
  24.             daycheck3()
  25.         elif mathhelp == "r" or mathhelp == "R":
  26.             daycheck4()
  27.         elif mathhelp == "stats and maths" or mathhelp == "STATS AND MATHS":
  28.             daycheck5()
  29.         elif mathhelp == "python" or mathhelp == "PYTHON":
  30.             daycheck6()
  31.         elif mathhelp == "maple" or mathhelp == "MAPLE":
  32.             daycheck7()
  33.         elif mathhelp == "spss" or mathhelp == "SPSS":
  34.             daycheck8()
  35.         elif mathhelp == "logic and sets" or mathhelp == "LOGIC AND SETS":
  36.             daycheck9()
  37.         elif mathhelp == "minitab" or mathhelp == "MINITAB":
  38.             daycheck10()
  39.         else:
  40.             print("Please enter a valid response")
  41.    
  42.            
  43.    
  44.  
  45. def daycheck():
  46.     #checks for what days user is free for excel support
  47.     dayfree = str(input("What day are you free "))
  48.    
  49.     if dayfree == "monday" or dayfree == "Monday":
  50.         print("Mark Hodds is free to help from 4pm-6pm")
  51.         sys.exit(0)
  52.     elif dayfree == "tuesday" or dayfree == "Tuesday":  
  53.         print("Sorry there is no one available on Tuesday for Excel support")
  54.         sys.exit(0)
  55.     elif dayfree == "wednesday" or dayfree == "Wednesday":
  56.         print ("Mark Hodds is available to help 2pm-4pm ")
  57.         sys.exit(0)
  58.     elif dayfree == "thursday" or dayfree == "Thursday":
  59.         print ("Mark Hodds is available to help 12pm-1pm ")
  60.         sys.exit(0)
  61.     elif dayfree == "friday" or dayfree == "Friday":
  62.         print ("Mark Hodds is available to help 10am-11am, 2pm-3pm and 5pm-6pm")
  63.         sys.exit(0)
  64.     elif dayfree == "saturday" or dayfree == "Saturday":
  65.         print ("Sorry no one is available for excel support on saturday")
  66.         sys.exit(0)
  67.     elif dayfree == "sunday" or dayfree == "Sunday":
  68.         print ("Sorry no one is available for excel support on sunday")
  69.         sys.exit(0)
  70.  
  71.              
  72.                
  73. def english():
  74.      #english fucntion
  75.     print ("To get english support please visit https://cawbookings.coventry.ac.uk/")
  76.  
  77. def daycheck2():  
  78. #checks for what days user is free for latex support
  79.     dayfree = str(input("What day are you free "))
  80.    
  81.     if dayfree == "monday" or dayfree == "Monday":
  82.         print("Aiping Xu is free from 11am-noon and 3pm-4pm ")
  83.         sys.exit(0)
  84.     elif dayfree == "tuesday" or dayfree == "Tuesday":  
  85.         print("Aiping Xu is free from 2pm-3pm and Jim Tabor is free from 3pm-5pm")
  86.         sys.exit(0)
  87.     elif dayfree == "wednesday" or dayfree == "Wednesday":
  88.         print ("James Griffin is free from 1pm-2pm, Mark Hodds is available from 2pm=4pm and Aiping Xu is free from 3pm-4pm ")
  89.         sys.exit(0)
  90.     elif dayfree == "thursday" or dayfree == "Thursday":
  91.         print ("Aiping Xu is free to help from 10am-noon  ")
  92.         sys.exit(0)
  93.     elif dayfree == "friday" or dayfree == "Friday":
  94.         print ("Mark Hodds is available to help 10am-11am, 2pm-3pm and 5pm-6pm")
  95.         sys.exit(0)
  96.     elif dayfree == "saturday" or dayfree == "Saturday":
  97.         print ("Sorry no one is available for Latex support on saturday")
  98.         sys.exit(0)
  99.     elif dayfree == "sunday" or dayfree == "Sunday":
  100.         print ("Sorry no one is available for Latex support on sunday")
  101.         sys.exit(0)
  102.        
  103. def daycheck3():  
  104. #checks for what days user is free for matlab support
  105.     dayfree = str(input("What day are you free "))
  106.    
  107.     if dayfree == "monday" or dayfree == "Monday":
  108.         print("Aiping Xu is free from 11am-noon and 3pm-4pm, Jia Shao is free from 2pm-4pm, Mark Hodds is free from 4pm-6pm and Jim Rabor is free from 6pm-8pm ")
  109.         sys.exit(0)
  110.     elif dayfree == "tuesday" or dayfree == "Tuesday":  
  111.         print("Aiping Xu is free from 2pm-3pm and Jim Tabor is free from 3pm-5pm")
  112.         sys.exit(0)
  113.     elif dayfree == "wednesday" or dayfree == "Wednesday":
  114.         print ("Jia Shao is free from 11am-1pm and Aiping Xu is free from 3pm-4pm ")
  115.         sys.exit(0)
  116.     elif dayfree == "thursday" or dayfree == "Thursday":
  117.         print ("Aiping Xu is free to help from 10am-noon, 2pm-4pm and Jim Tabor is free from 4pm-5pm  ")
  118.         sys.exit(0)
  119.     elif dayfree == "friday" or dayfree == "Friday":
  120.         print ("Jia Shao is free from 3pm-5pm ")
  121.         sys.exit(0)
  122.     elif dayfree == "saturday" or dayfree == "Saturday":
  123.         print ("Sorry no one is available for matlab support on saturday")
  124.         sys.exit(0)
  125.     elif dayfree == "sunday" or dayfree == "Sunday":
  126.         print ("Sorry no one is available for matlab support on sunday")
  127.         sys.exit(0)  
  128.    
  129. def daycheck4():  
  130. #checks for what days user is free for R support
  131.     dayfree = str(input("What day are you free "))
  132.    
  133.     if dayfree == "monday" or dayfree == "Monday":
  134.         print("Liam Brierely is free from noon-1pm and Jia Shao is free from 2pm-4pm ")
  135.         sys.exit(0)
  136.     elif dayfree == "tuesday" or dayfree == "Tuesday":  
  137.         print("Sorry no one is free for R support ")
  138.         sys.exit(0)
  139.     elif dayfree == "wednesday" or dayfree == "Wednesday":
  140.         print ("Jia Shao is free from 11am-1pm ")
  141.         sys.exit(0)
  142.     elif dayfree == "thursday" or dayfree == "Thursday":
  143.         print ("Liam Brierely is free from 2pm-4pm  ")
  144.         sys.exit(0)
  145.     elif dayfree == "friday" or dayfree == "Friday":
  146.         print ("Liam Brierely is free from 11am-2pm and Jia Shao is free from 3pm-5pm ")
  147.         sys.exit(0)
  148.     elif dayfree == "saturday" or dayfree == "Saturday":
  149.         print ("Sorry no one is available for R support on saturday")
  150.         sys.exit(0)
  151.     elif dayfree == "sunday" or dayfree == "Sunday":
  152.         print ("Sorry no one is available for R support on sunday")
  153.         sys.exit(0)    
  154.  
  155. def daycheck5():  
  156. #checks for what days user is free for R support
  157.     dayfree = str(input("What day are you free "))
  158.    
  159.     if dayfree == "monday" or dayfree == "Monday":
  160.         print("Mark Hodds is free from 4pm-6pm  ")
  161.         sys.exit(0)
  162.     elif dayfree == "tuesday" or dayfree == "Tuesday":  
  163.         print("Sorry no one is free for stats and maths support ")
  164.         sys.exit(0)
  165.     elif dayfree == "wednesday" or dayfree == "Wednesday":
  166.         print ("Mark Hodds is free from 2pm-4pm ")
  167.         sys.exit(0)
  168.     elif dayfree == "thursday" or dayfree == "Thursday":
  169.         print (" Mark Hodds is free from noon-1pm  ")
  170.         sys.exit(0)
  171.     elif dayfree == "friday" or dayfree == "Friday":
  172.         print ("Mark Hodds is free from 10am-11am, 2pm-3pm and 5pm-6pm  ")
  173.         sys.exit(0)
  174.     elif dayfree == "saturday" or dayfree == "Saturday":
  175.         print ("Sorry no one is available for stats and maths support on saturday")
  176.         sys.exit(0)
  177.     elif dayfree == "sunday" or dayfree == "Sunday":
  178.         print ("Sorry no one is available for stats and maths support on sunday")
  179.         sys.exit(0)  
  180.  
  181. def daycheck6():  
  182. #checks for what days user is free for python support
  183.     dayfree = str(input("What day are you free "))
  184.    
  185.     if dayfree == "monday" or dayfree == "Monday":
  186.         print("sorry no one is available for python support  ")
  187.         sys.exit(0)
  188.     elif dayfree == "tuesday" or dayfree == "Tuesday":  
  189.         print("Sorry no one is free for stats and maths support ")
  190.         sys.exit(0)
  191.     elif dayfree == "wednesday" or dayfree == "Wednesday":
  192.         print ("James Griffin is free from 1pm-2pm ")
  193.         sys.exit(0)
  194.     elif dayfree == "thursday" or dayfree == "Thursday":
  195.         print (" James griffin is free from 2pm-3pm  ")
  196.         sys.exit(0)
  197.     elif dayfree == "friday" or dayfree == "Friday":
  198.         print (" sorry no one is available for python support  ")
  199.         sys.exit(0)
  200.     elif dayfree == "saturday" or dayfree == "Saturday":
  201.         print ("Sorry no one is available for python support")
  202.         sys.exit(0)
  203.     elif dayfree == "sunday" or dayfree == "Sunday":
  204.         print ("Sorry no one is available for python support")
  205.         sys.exit(0)
  206.  
  207. def daycheck7():  
  208. #checks for what days user is free for Maple support
  209.     dayfree = str(input("What day are you free "))
  210.    
  211.     if dayfree == "monday" or dayfree == "Monday":
  212.         print(" Jim Tabor is free from 6pm-8pm  ")
  213.         sys.exit(0)
  214.     elif dayfree == "tuesday" or dayfree == "Tuesday":  
  215.         print("Jim Tabor is free from 3pm-5pm ")
  216.         sys.exit(0)
  217.     elif dayfree == "wednesday" or dayfree == "Wednesday":
  218.         print ("Sorry no one is available for Maple support ")
  219.         sys.exit(0)
  220.     elif dayfree == "thursday" or dayfree == "Thursday":
  221.         print (" Jim Tabor is free from 2pm-3pm   ")
  222.         sys.exit(0)
  223.     elif dayfree == "friday" or dayfree == "Friday":
  224.         print (" sorry no one is available for maple support  ")
  225.         sys.exit(0)
  226.     elif dayfree == "saturday" or dayfree == "Saturday":
  227.         print ("Sorry no one is available for maple support")
  228.         sys.exit(0)
  229.     elif dayfree == "sunday" or dayfree == "Sunday":
  230.         print ("Sorry no one is available for maple support")
  231.         sys.exit(0)
  232.        
  233. def daycheck8():  
  234. #checks for what days user is free for SPSS support
  235.     dayfree = str(input("What day are you free "))
  236.    
  237.     if dayfree == "monday" or dayfree == "Monday":
  238.         print(" Liam Brierely is free from noon-1pm, Jia Shao is free from 2pm-4pm and Mark Hodds is free from 4pm-6pm  ")
  239.         sys.exit(0)
  240.     elif dayfree == "tuesday" or dayfree == "Tuesday":  
  241.         print("Tim Sparks is free from 1pm-3pm ")
  242.         sys.exit(0)
  243.     elif dayfree == "wednesday" or dayfree == "Wednesday":
  244.         print ("Jia Shao is free from 11am-1pm and Mark Hodds is free from 2pm-4pm ")
  245.         sys.exit(0)
  246.     elif dayfree == "thursday" or dayfree == "Thursday":
  247.         print (" Mark Hodds is free from noon-1pm, Liam Brierely is free from 2pm-4pm and Tim Sparks is free from 4pm-6pm   ")
  248.         sys.exit(0)
  249.     elif dayfree == "friday" or dayfree == "Friday":
  250.         print (" Mark Hodds is free from 10am-11am, 2pm-3pm, 5pm-6pm. Liam Brierely is free from 11am-2pm and Jia Shao is free from 3pm-5pm    ")
  251.         sys.exit(0)
  252.     elif dayfree == "saturday" or dayfree == "Saturday":
  253.         print ("Sorry no one is available for SPSS support")
  254.         sys.exit(0)
  255.     elif dayfree == "sunday" or dayfree == "Sunday":
  256.         print ("Sorry no one is available for SPSS support")
  257.         sys.exit(0)    
  258.        
  259. def daycheck9():  
  260. #checks for what days user is free for Logic and sets support
  261.     dayfree = str(input("What day are you free "))
  262.    
  263.     if dayfree == "monday" or dayfree == "Monday":
  264.         print("Aiping Xu is free from 11-noon and 3pm-4pm  ")
  265.         sys.exit(0)
  266.     elif dayfree == "tuesday" or dayfree == "Tuesday":  
  267.         print("Dorothea Kondrat is free from noon-2pm and Aiping Xu is free from 2pm-3pm ")
  268.         sys.exit(0)
  269.     elif dayfree == "wednesday" or dayfree == "Wednesday":
  270.         print ("Aiping Xu is free from 3pm-4pm ")
  271.         sys.exit(0)
  272.     elif dayfree == "thursday" or dayfree == "Thursday":
  273.         print (" Aiping Xu is free from 10am-noon and 2pm-4pm  ")
  274.         sys.exit(0)
  275.     elif dayfree == "friday" or dayfree == "Friday":
  276.         print ("Sorry no one is available for logic and sets support   ")
  277.         sys.exit(0)
  278.     elif dayfree == "saturday" or dayfree == "Saturday":
  279.         print ("Sorry no one is available for logic and sets support ")
  280.         sys.exit(0)
  281.     elif dayfree == "sunday" or dayfree == "Sunday":
  282.         print ("Sorry no one is available for logic and sets support ")
  283.         sys.exit(0)  
  284.        
  285.        
  286. #Main fucntion call where the function support is called    
  287. def main():
  288.     support()
  289.  
  290.  
  291. if __name__ == "__main__":
  292.     main()
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement