Guest User

Project 1

a guest
Apr 7th, 2016
49
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Python 26.80 KB | None | 0 0
  1. #Create a Python program that will simulate:
  2. #1. Booting up a Computer
  3. #2. Entering a username / password to get into the Desktop
  4. #3. Open up a program and have the program do something
  5. #4. System Check (CONTROL ALT DELETE PROCESSES)
  6. #5. Logoff
  7. #6. Reboot / Shut Down
  8. #Utilize: Keyboard, mouse, monitor etc.
  9. #When these options are activating from the Class you created, each specific thing should have functions that will run from it.
  10. #Your program must have:
  11. #Classes(Module you created)
  12. #Functions
  13. #Arrays
  14. #If using anything you didn't learn in class, site it and write what it does and everything.
  15.  
  16. def bootup():
  17.   print ""
  18.   print "Booting up..."
  19.   print "=" * 80
  20.   print "Loading programs..."
  21.   print "=" * 80
  22.   print "Updating software..."
  23.   print "=" * 80
  24.   print "Finding devices..."
  25.   print "Mouse found."
  26.   print "Keyboard found."
  27.   print "Printer found."
  28.   print "=" * 80
  29.   print "Connect to interent..."
  30.   print "....."
  31.   print "..."
  32.   print "Connected."
  33.   print "=" * 80#This is the function to bootup the computer
  34.  
  35. def logoff():
  36.   print "=" * 80
  37.   print "Closing all programs..."
  38.   print "=" * 80
  39.   print "Closing all background programs..."
  40.   print "=" * 80
  41.   print "Logging off..."
  42.   print "=" * 80
  43.   print "Loading..."
  44.   print "=" * 80
  45.   sign_in()#This is the function to logoff the user
  46.  
  47. def reboot():
  48.   print "=" * 80
  49.   print "Closing all programs..."
  50.   print "=" * 80
  51.   print "Closing all background programs..."
  52.   print "=" * 80
  53.   print "Loading..."
  54.   print "=" * 80
  55.   print "Rebooting..."
  56.   print "....."
  57.   print "..."
  58.   bootup()
  59.   sign_in()#This is the function to reboot the computer
  60.  
  61. def shut_down(): #This is the function to shut down the computer
  62.   print "=" * 80
  63.   print "Are you sure you want to shut down?"
  64.   answer=raw_input()
  65.   if answer=="yes":
  66.     print "Closing all programs..."
  67.     print "=" * 80
  68.     print "Closing all background programs..."
  69.     print "=" * 80
  70.     print "Loading..."
  71.     print "=" * 80
  72.     print "Shutting down..."
  73.     print "....."
  74.     print "..."
  75.     print "."
  76.   elif answer=="Yes":
  77.     print "Closing all programs..."
  78.     print "=" * 80
  79.     print "Closing all background programs..."
  80.     print "=" * 80
  81.     print "Loading..."
  82.     print "=" * 80
  83.     print "Shutting down..."
  84.     print "....."
  85.     print "..."
  86.     print "."
  87.   elif answer=="no":
  88.     print "Okay"
  89.     options()
  90.   elif answer=="No":
  91.     print "Okay"
  92.     options()
  93.   else:
  94.     print "Try again."
  95.     shut_down()
  96.    
  97. def task_manager(): #This is the function to go to task manger and kill programs
  98.   task1 = "ScheduleMe"
  99.   task2 = "Wireless Connection"
  100.   task3 = "Find My Element"
  101.   task4 = "Printer"
  102.   tasks=[task1,task2,task3,task4]
  103.   print tasks
  104.   task = raw_input("What program would you like to kill?")
  105.   if task==task1:
  106.     print "done"
  107.     tasks=[task2,task3,task4]
  108.     print tasks
  109.     options()
  110.   elif task==task2:
  111.     print "done"
  112.     tasks=[task1,task3,task4]
  113.     print tasks
  114.     options()
  115.   elif task==task3:
  116.     print "done"
  117.     tasks=[task1,task2,task4]
  118.     print tasks
  119.     options()
  120.   elif task==task4:
  121.     print "done"
  122.     tasks=[task1,task2,tasks]
  123.     print tasks
  124.     options()
  125.   else:
  126.     print "Error. Try again"
  127.     task_manager()
  128.  
  129. def options(): #This is the function to go to start menu
  130.   print "=" * 80
  131.   print "Choose corresponding number:"
  132.   print "1. Logoff"
  133.   print "2. Reboot"
  134.   print "3. Shut Down"
  135.   print "4. Task Manager"
  136.   print "5. Back"
  137.   choice=raw_input()
  138.   if choice=="1":
  139.     logoff()
  140.   elif choice=="2":
  141.     reboot()
  142.   elif choice=="3":
  143.     shut_down()
  144.   elif choice=="4":
  145.     task_manager()
  146.   elif choice=="5":
  147.     desktop_screen()
  148.   else:
  149.     print "Error!!!"
  150.    
  151.  
  152. def element(): # Define main function that encompasses everything in the find my element program
  153.   global element
  154.   print "=" * 22
  155.   print "Find my element."
  156.   print "=" * 22
  157.  
  158.   # Instructions for how to use program
  159.   print "Section 1: consists of periods 1 & 2"
  160.   print "Section 2: consists of periods 3 through 8"
  161.   print "Section 3: consists of transition metals"
  162.   print "Section 4: consists of Lanthanoids and Actinoids"
  163.   print "(Or type \'0\' to go back)"
  164.   period = raw_input("Choose your section [1-4]:") # choose section for where the program will look for your element
  165.  
  166.   if period == "1": # takes raw input and places reads it and outputs what section of the periodic table the user should choose from
  167.     print "Choose an element's initials from period 1 or 2 (Case Sensitive):"
  168.   elif period == "2":
  169.     print "Choose an element's initials from periods 3 through 8 (Case Sensitive):"
  170.   elif period == "3":
  171.     print "Choose a transition metal's initials (Case Sensitive):"
  172.   elif period == "4":
  173.     print "Choose a Lanthanoid's initials or an Actinoid's initials (Case Sensitive):"
  174.   elif period == "0" :
  175.     desktop_screen()
  176.   elif period == "ctrl alt delete":
  177.     options()
  178.   else:
  179.     print "Try again..."
  180.     element()
  181.  
  182.   a = "atomic number" # strings for easier coding below
  183.   b = "atomic mass"
  184.  
  185.   element = raw_input("Choose your element") # asks user to input the element
  186.   element = element
  187.  
  188.   def period_1_and_2(Period12): # defines function for periods 1 and 2
  189.     if element == "H":
  190.       print "Hydrogen \n %s: 1 \n %s: 1.008" % (a,b)
  191.       desktop_screen()
  192.     elif element == "Li":
  193.       print "Lithium \n %s: 3 \n %s: 6.941" % (a,b)
  194.       desktop_screen()
  195.     elif element == "Na":
  196.       print "Sodium \n %s: 11 \n %s: 22.990" % (a,b)
  197.       desktop_screen()
  198.     elif element == "K":
  199.       print "Potassium \n %s: 19 \n %s: 39.098" % (a,b)
  200.       desktop_screen()
  201.     elif element == "Rb":
  202.       print "Rubidium \n %s: 37 \n %s: 84.468" % (a,b)
  203.       desktop_screen()
  204.     elif element == "Cs":
  205.       print "Cesium \n %s: 55 \n %s: 132.905" % (a,b)
  206.       desktop_screen()
  207.     elif element == "Fr":
  208.       print "Francium \n %s: 87 \n %s: 223.020" % (a,b)
  209.       desktop_screen()
  210.     elif element == "Be":
  211.       print "Beryllium \n %s: 4 \n %s: 9.012" % (a,b)
  212.       desktop_screen()
  213.     elif element == "Mg":
  214.       print "Magnesium \n %s: 12 \n %s: 24.305" % (a,b)
  215.       desktop_screen()
  216.     elif element == "Ca":
  217.       print "Calcium \n %s: 20 \n %s: 40.078" % (a,b)
  218.       desktop_screen()
  219.     elif element == "Sr":
  220.       print "Strontium \n %s: 38 \n %s: 87.62" % (a,b)
  221.       desktop_screen()
  222.     elif element == "Ba":
  223.       print "Barium \n %s: 56 \n %s: 137.328" % (a,b)
  224.       desktop_screen()
  225.     elif element == "Ra":
  226.       print "Radium \n %s: 88 \n %s: 226.025" % (a,b)
  227.       desktop_screen()
  228.     elif element == "ctrl alt delete":
  229.       options()
  230.   period_1_and_2("Period12") # calls the the function above
  231.  
  232.   def period_3_to_8(Period38): # defines function for periods 3 through 8
  233.     if element == "B":
  234.       print "Boron \n %s: 5 \n %s: 10.81" % (a,b)
  235.       desktop_screen()
  236.     elif element == "Al":
  237.       print "Aluminium \n %s: 13 \n %s: 26.9815385" % (a,b)
  238.       desktop_screen()
  239.     elif element == "Ga":
  240.       print "Gallium \n %s: 31 \n %s: 69.723" % (a,b)
  241.       desktop_screen()
  242.     elif element == "In":
  243.       print "Indium \n %s: 49 \n %s: 114.818" % (a,b)
  244.       desktop_screen()
  245.     elif element == "Ti":
  246.       print "Thallium \n %s: 81 \n %s: 204.38" % (a,b)
  247.       desktop_screen()
  248.     elif element == "C":
  249.       print "Carbon \n %s: 6 \n %s: 12.001" % (a,b)
  250.       desktop_screen()
  251.     elif element == "Si":
  252.       print "Silicon \n %s: 14 \n %s: 28.085" % (a,b)
  253.       desktop_screen()
  254.     elif element == "Ge":
  255.       print "Germanium \n %s: 32 \n %s: 72.63" % (a,b)
  256.       desktop_screen()
  257.     elif element == "Sn":
  258.       print "Tin \n %s: 50 \n %s: 118.710" % (a,b)
  259.       desktop_screen()
  260.     elif element == "Pb":
  261.       print "Lead \n %s: 82 \n %s: 207.2" % (a,b)
  262.       desktop_screen()
  263.     elif element == "N":
  264.       print "Nitrogen \n %s: 7 \n %s: 14.007" % (a,b)
  265.       desktop_screen()
  266.     elif element == "P":
  267.       print "Phosphorus \n %s: 15 \n %s: 30.973761998" % (a,b)
  268.       desktop_screen()
  269.     elif element == "As":
  270.       print "Arsenic \n %s: 33 \n %s: 74.921595" % (a,b)
  271.       desktop_screen()
  272.     elif element == "Sb":
  273.       print "Antimony \n %s: 51 \n %s: 121.760" % (a,b)
  274.       desktop_screen()
  275.     elif element == "Bi":
  276.       print "Bismuth \n %s: 83 \n %s: 208.98040" % (a,b)
  277.       desktop_screen()
  278.     elif element == "O":
  279.       print "Oxygen \n %s: 8 \n %s: 15.999" % (a,b)
  280.       desktop_screen()
  281.     elif element == "S":
  282.       print "Sulfur \n %s: 16 \n %s: 32.06" % (a,b)
  283.       desktop_screen()
  284.     elif element == "Se":
  285.       print "Selenium \n %s: 34 \n %s: 78.971" % (a,b)
  286.       desktop_screen()
  287.     elif element == "Te":
  288.       print "Tellurium \n %s: 52 \n %s: 127.60" % (a,b)
  289.       desktop_screen()
  290.     elif element == "Po":
  291.       print "Polonium \n %s: 84 \n %s: 209" % (a,b)
  292.       desktop_screen()
  293.     elif element == "F":
  294.       print "Fluorine \n %s: 9 \n %s: 18.998403163" % (a,b)
  295.       desktop_screen()
  296.     elif element == "Cl":
  297.       print "Chlorine \n %s: 17 \n %s: 35.45" % (a,b)
  298.       desktop_screen()
  299.     elif element == "Br":
  300.       print "Bromine \n %s: 35 \n %s: 79.904" % (a,b)
  301.       desktop_screen()
  302.     elif element == "I":
  303.       print "Iodine \n %s: 53 \n %s: 126.90447" % (a,b)
  304.       desktop_screen()
  305.     elif element == "At":
  306.       print "Astatine \n %s: 85 \n %s: 210" % (a,b)
  307.       desktop_screen()
  308.     elif element == "He":
  309.       print "Helium \n %s: 2 \n %s: 4.002602" % (a,b)
  310.       desktop_screen()
  311.     elif element == "Ne":
  312.       print "Neon \n %s: 10 \n %s: 20.1797" % (a,b)
  313.       desktop_screen()
  314.     elif element == "Ar":
  315.       print "Argon \n %s: 18 \n %s 39.948" % (a,b)
  316.       desktop_screen()
  317.     elif element == "Kr":
  318.       print "Krypton \n %s: 36 \n %s: 83.798" % (a,b)
  319.       desktop_screen()
  320.     elif element == "Xe":
  321.       print "Xenon \n %s: 54 \n %s: 131.293" % (a,b)
  322.       desktop_screen()
  323.     elif element == "Rn":
  324.       print "Radon \n %s: 86 \n %s: 222" % (a,b)
  325.       desktop_screen()
  326.     elif element == "ctrl alt delete":
  327.       options()
  328.   period_3_to_8("Period38") # calls the the function above
  329.  
  330.   def transition_metals(Transition): # defines function for all transition metals
  331.     if element == "Sc":
  332.       print "Scandium \n %s: 21 \n %s: 44.956" % (a,b)
  333.       desktop_screen()
  334.     elif element == "Ti":
  335.       print "Titanium \n %s: 22 \n %s: 47.867" % (a,b)
  336.       desktop_screen()
  337.     elif element == "V":
  338.       print "Vanadium \n %s: 23 \n %s: 50.942" % (a,b)
  339.       desktop_screen()
  340.     elif element == "Cr":
  341.       print "Chromium \n %s: 24 \n %s: 51.996" % (a,b)
  342.       desktop_screen()
  343.     elif element == "Mn":
  344.       print "Manganese \n %s: 25 \n %s: 54.938" % (a,b)
  345.       desktop_screen()
  346.     elif element == "Fe":
  347.       print "Iron \n %s: 26 \n %s: 55.845" % (a,b)
  348.       desktop_screen()
  349.     elif element == "Co":
  350.       print "Cobalt \n %s: 27 \n %s: 58.933" % (a,b)
  351.       desktop_screen()
  352.     elif element == "Ni":
  353.       print "Nickel \n %s: 28 \n %s: 58.693" % (a,b)
  354.       desktop_screen()
  355.     elif element == "Cu":
  356.       print "Copper \n %s: 29 \n %s: 63.546" % (a,b)
  357.       desktop_screen()
  358.     elif element == "Zn":
  359.       print "Zinc \n %s: 30 \n %s: 65.38" % (a,b)
  360.       desktop_screen()
  361.     elif element == "Y":
  362.       print "Yttrium \n %s: 39 \n %s: 88.906" % (a,b)
  363.       desktop_screen()
  364.     elif element == "Zr":
  365.       print "Zirconium \n %s: 40 \n %s: 91.224" % (a,b)
  366.       desktop_screen()
  367.     elif element == "Nb":
  368.       print "Niobiium \n %s: 41 \n %s: 92.906" % (a,b)
  369.       desktop_screen()
  370.     elif element == "Mo":
  371.       print "Molybdenum \n %s: 42 \n %s: 95.95" % (a,b)
  372.       desktop_screen()
  373.     elif element == "Tc":
  374.       print "Technetium \n %s: 43 \n %s: 98.907" % (a,b)
  375.       desktop_screen()
  376.     elif element == "Ru":
  377.       print "Ruthenium \n %s: 44 \n %s: 101.07" % (a,b)
  378.       desktop_screen()
  379.     elif element == "Rh":
  380.       print "Rhodium \n %s: 45 \n %s: 102.906" % (a,b)
  381.       desktop_screen()
  382.     elif element == "Pd":
  383.       print "Palladium \n %s: 46 \n %s: 106.42" % (a,b)
  384.       desktop_screen()
  385.     elif element == "Ag":
  386.       print "Silver \n %s: 47 \n %s: 107.868" % (a,b)
  387.       desktop_screen()
  388.     elif element == "Cd":
  389.       print "Cadmium \n %s: 48 \n %s: 112.414" % (a,b)
  390.       desktop_screen()
  391.     elif element == "Hf":
  392.       print "Hafnium \n %s: 72 \n %s: 178.49" % (a,b)
  393.       desktop_screen()
  394.     elif element == "Ta":
  395.       print "Tantalum \n %s: 73 \n %s: 180.948" % (a,b)
  396.       desktop_screen()
  397.     elif element == "W":
  398.       print "Tungsten \n %s: 74 \n %s: 183.84" % (a,b)
  399.       desktop_screen()
  400.     elif element == "Re":
  401.       print "Rhenium \n %s: 75 \n %s: 186.207" % (a,b)
  402.       desktop_screen()
  403.     elif element == "Os":
  404.       print "Osmium \n %s: 76 \n %s: 190.23" % (a,b)
  405.       desktop_screen()
  406.     elif element == "Ir":
  407.       print "Iridium \n %s: 77 \n %s: 192.217" % (a,b)
  408.       desktop_screen()
  409.     elif element == "Pt":
  410.       print "Platinum \n %s: 78 \n %s: 195.085" % (a,b)
  411.       desktop_screen()
  412.     elif element == "Au":
  413.       print "Gold \n %s: 79 \n %s: 196.967" % (a,b)
  414.       desktop_screen()
  415.     elif element == "Hg":
  416.       print "Mercury \n %s: 80 \n %s: 200.592" % (a,b)
  417.       desktop_screen()
  418.     elif element == "Rf":
  419.       print "Rutherfordium \n %s: 104 \n %s: 261" % (a,b)
  420.       desktop_screen()
  421.     elif element == "Db":
  422.       print "Dubnium \n %s: 105 \n %s: 262" % (a,b)
  423.       desktop_screen()
  424.     elif element == "Sg":
  425.       print "Seaborgium \n %s: 106 \n %s: 266" % (a,b)
  426.       desktop_screen()
  427.     elif element == "Bh":
  428.       print "Bohrium \n %s: 107 \n %s: 264" % (a,b)
  429.       desktop_screen()
  430.     elif element == "Hs":
  431.       print "Hassium \n %s: 108 \n %s: 269" % (a,b)
  432.       desktop_screen()
  433.     elif element == "Mt":
  434.       print "Meitnerium \n %s: 109 \n %s: 268" % (a,b)
  435.       desktop_screen()
  436.     elif element == "Ds":
  437.       print "Darmstadtium \n %s: 110 \n %s: 269" % (a,b)
  438.       desktop_screen()
  439.     elif element == "Rg":
  440.       print "Roentgenium \n %s: 111 \n %s: 272" % (a,b)
  441.       desktop_screen()
  442.     elif element == "Cn":
  443.       print "Copernicium \n %s: 112 \n %s: 277" % (a,b)
  444.       desktop_screen()
  445.     elif element == "ctrl alt delete":
  446.       options()
  447.   transition_metals("Transition") # calls the the function above
  448.  
  449.   def lanthanoids_and_actinoids(lanthanoids_and_actinoids): # defines the function for lanthanoids and actinoids
  450.     if element == "La":
  451.      print "Lanthanum \n %s: 57 \n %s: 138.905" % (a,b)
  452.      desktop_screen()
  453.     elif element == "Ce":
  454.       print "Cerium \n %s: 58 \n %s: 140.116" % (a,b)
  455.       desktop_screen()
  456.     elif element == "Pr":
  457.       print "Praseodymium \n %s: 59 \n %s: 140.908" % (a,b)
  458.       desktop_screen()
  459.     elif element == "Nd":
  460.       print "Neodymium \n %s: 60 \n %s: 144.243" % (a,b)
  461.       desktop_screen()
  462.     elif element == "Pm":
  463.       print "Promethium \n %s: 61 \n %s: 144.913" % (a,b)
  464.       desktop_screen()
  465.     elif element == "Sm":
  466.       print "Samarium \n %s: 62 \n %s: 150.36" % (a,b)
  467.       desktop_screen()
  468.     elif element == "Eu":
  469.       print "Europium \n %s: 63 \n %s: 151.964" % (a,b)
  470.       desktop_screen()
  471.     elif element == "Gd":
  472.       print "Gadolinium \n %s: 64 \n %s: 157.25" % (a,b)
  473.       desktop_screen()
  474.     elif element == "Tb":
  475.       print "Terbium \n %s: 65 \n %s: 158.925" % (a,b)
  476.       desktop_screen()
  477.     elif element == "Dy":
  478.       print "Dysprosium \n %s: 66 \n %s: 162.500" % (a,b)
  479.       desktop_screen()
  480.     elif element == "Ho":
  481.       print "Holmium \n %s: 67 \n %s: 164.930" % (a,b)
  482.       desktop_screen()
  483.     elif element == "Er":
  484.       print "Erbium \n %s: 68 \n %s: 167.259" % (a,b)
  485.       desktop_screen()
  486.     elif element == "Tm":
  487.       print "Thulium \n %s: 69 \n %s: 168.934" % (a,b)
  488.       desktop_screen()
  489.     elif element == "Yb":
  490.       print "Ytterbium \n %s: 70 \n %s: 173.055" % (a,b)
  491.       desktop_screen()
  492.     elif element == "Lu":
  493.       print "Lutetium \n %s:71 \n %s: 174.967" % (a,b)
  494.       desktop_screen()
  495.     elif element == "Ac":
  496.       print "Actinium \n %s: 89 \n %s: 227.028" % (a,b)
  497.       desktop_screen()
  498.     elif element == "Th":
  499.       print "Thorium \n %s: 90 \n %s: 232.038" % (a,b)
  500.       desktop_screen()
  501.     elif element == "Pa":
  502.       print "Protactinium \n %s: 91 \n %s: 231.036" % (a,b)
  503.       desktop_screen()
  504.     elif element == "U":
  505.       print "Uranium \n %s: 92 \n %s: 238.029" % (a,b)
  506.       desktop_screen()
  507.     elif element == "Np":
  508.       print "Neptunium \n %s: 93 \n %s: 237.048" % (a,b)
  509.       desktop_screen()
  510.     elif element == "Pu":
  511.       print "Plutonium \n %s: 94 \n %s: 244.064" % (a,b)
  512.       desktop_screen()
  513.     elif element == "Am":
  514.       print "Americium \n %s: 95 \n %s: 243.061" % (a,b)
  515.       desktop_screen()
  516.     elif element == "Cm":
  517.       print "Curium \n %s: 96 \n %s: 247.070" % (a,b)
  518.       desktop_screen()
  519.     elif element == "Bk":
  520.       print "Berkelium \n %s:97 \n %s: 247.070" % (a,b)
  521.       desktop_screen()
  522.     elif element == "Cf":
  523.       print "Californium \n %s:98 \n %s: 251.080" % (a,b)
  524.       desktop_screen()
  525.     elif element == "Es":
  526.       print "Einsteinium \n %s: 99 \n %s: 254" % (a,b)
  527.       desktop_screen()
  528.     elif element == "Fm":
  529.       print "Fermium \n %s: 100 \n %s: 257.095" % (a,b)
  530.       desktop_screen()
  531.     elif element == "Md":
  532.       print "Mendelevium \n %s: 101 \n %s: 258.1" % (a,b)
  533.       desktop_screen()
  534.     elif element == "No":
  535.       print "Nobelium \n %s: 102 \n %s: 259.101" % (a,b)
  536.       desktop_screen()
  537.     elif element == "Lr":
  538.       print "Lawrencium \n %s: 103 \n %s: 262" % (a,b)
  539.       desktop_screen()
  540.     elif element == "ctrl alt delete":
  541.       options()
  542.   lanthanoids_and_actinoids("Lanthanoid_and_actinoids") # calls the the function above
  543.  
  544. def sheduleme(): #defines funcion ScheduleMe which is used to find my schedule
  545.   def a_day(arg1,arg2,arg3,arg4,arg5,arg6,arg7,arg8): # defines function for A day
  546.     print (50 * '=')
  547.     print '''On A-Day you will have:
  548.    First Period -> %s
  549.    Second Period -> %s
  550.    Community Period -> %s
  551.    Third Period -> %s
  552.    Fourth Period -> %s
  553.    Lunch -> %s
  554.    Fifth Period -> %s
  555.    Sixth Period -> %s
  556.    '''%(arg1,arg2,arg3,arg4,arg5,arg6,arg7,arg8)
  557.  
  558.   def b_day(arg1,arg2,arg3,arg4,arg5,arg6,arg7,arg8): # defines function for B Day
  559.     print (50 * '=')
  560.     print '''On B-Day you will have:
  561.    First Period -> %s
  562.    Second Period -> %s
  563.    Community Period -> %s
  564.    Third Period -> %s
  565.    Fourth Period -> %s
  566.    Lunch -> %s
  567.    Fifth Period -> %s
  568.    Sixth Period -> %s
  569.    '''%(arg1,arg2,arg3,arg4,arg5,arg6,arg7,arg8)
  570.  
  571.   def c_day(arg1,arg2,arg3,arg4,arg5,arg6,arg7,arg8): # defines function for C Day
  572.     print (50 * '=')
  573.     print '''On C-Day you will have:
  574.    First Period -> %s
  575.    Second Period -> %s
  576.    Community Period -> %s
  577.    Third Period -> %s
  578.    Fourth Period -> %s
  579.    Lunch -> %s
  580.    Fifth Period -> %s
  581.    Sixth Period -> %s
  582.    '''%(arg1,arg2,arg3,arg4,arg5,arg6,arg7,arg8)
  583.  
  584.   def d_day(arg1,arg2,arg3,arg4,arg5,arg6,arg7,arg8): # defines function for D Day
  585.     print (50 * '=')
  586.     print '''On D-Day you will have:
  587.    First Period -> %s
  588.    Second Period -> %s
  589.    Community Period -> %s
  590.    Third Period -> %s
  591.    Fourth Period -> %s
  592.    Lunch -> %s
  593.    Fifth Period -> %s
  594.    Sixth Period -> %s
  595.    '''%(arg1,arg2,arg3,arg4,arg5,arg6,arg7,arg8)
  596.  
  597.   def e_day(arg1,arg2,arg3,arg4,arg5,arg6,arg7,arg8): # defines function for E Day
  598.     print (50 * '=')
  599.     print '''On E-Day you will have:
  600.    First Period -> %s
  601.    Second Period -> %s
  602.    Community Period -> %s
  603.    Third Period -> %s
  604.    Fourth Period -> %s
  605.    Lunch -> %s
  606.    Fifth Period -> %s
  607.    Sixth Period -> %s
  608.    '''%(arg1,arg2,arg3,arg4,arg5,arg6,arg7,arg8)
  609.  
  610.   def f_day(arg1,arg2,arg3,arg4,arg5,arg6,arg7,arg8): # defines function for F Day
  611.     print (50 * '=')
  612.     print '''On F-Day you will have:
  613.    First Period -> %s
  614.    Second Period -> %s
  615.    Community Period -> %s
  616.    Third Period -> %s
  617.    Fourth Period -> %s
  618.    Lunch -> %s
  619.    Fifth Period -> %s
  620.    Sixth Period -> %s
  621.    '''%(arg1,arg2,arg3,arg4,arg5,arg6,arg7,arg8)
  622.  
  623.   def g_day(arg1,arg2,arg3,arg4,arg5,arg6,arg7,arg8): # defines function for G Day
  624.     print (50 * '=')
  625.     print '''On G-Day you will have:
  626.    First Period -> %s
  627.    Second Period -> %s
  628.    Community Period -> %s
  629.    Third Period -> %s
  630.    Fourth Period -> %s
  631.    Lunch -> %s
  632.    Fifth Period -> %s
  633.    Sixth Period -> %s
  634.    '''%(arg1,arg2,arg3,arg4,arg5,arg6,arg7,arg8)
  635.  
  636.   def h_day(arg1,arg2,arg3,arg4,arg5,arg6,arg7,arg8): # defines function for H Day
  637.     print (50 * '=')
  638.     print '''On H-Day you will have:
  639.    First Period -> %s
  640.    Second Period -> %s
  641.    Community Period -> %s
  642.    Third Period -> %s
  643.    Fourth Period -> %s
  644.    Lunch -> %s
  645.    Fifth Period -> %s
  646.    Sixth Period -> %s
  647.    '''%(arg1,arg2,arg3,arg4,arg5,arg6,arg7,arg8)
  648.  
  649.   def answers(): # defines a function that asks user if they need anyting from program
  650.     print "=" * 80
  651.     print "Anything else? (Yes/No)",
  652.     answer=raw_input()
  653.     if answer=="Yes":
  654.       print "Okay restarting..."
  655.       questions()
  656.     elif answer=="yes":
  657.       print "Okay restarting..."
  658.       questions()
  659.     elif answer=="No":
  660.       desktop_screen()
  661.     elif answer=="no":
  662.       desktop_screen()
  663.     elif answer == "ctrl alt delete":
  664.       options()
  665.     else:
  666.       print "Try again..."
  667.       answers()
  668.  
  669.   def questions(): # defines the function that asks the user what day it is
  670.     print "=" * 80
  671.     print "Hello!Choose what letter day is it? Ex: \'A\',\'B\'. "
  672.     print "(Or type \'0\' to go back)"
  673.     question=raw_input()
  674.     if question=="A":
  675.       a_day("Chemistry in MSC318","The New Testament in H301","Homeroom in MSC318","Geometry Honors in H305","Video Production in MSC016","Follow Junior/Senior Lunch","English in E403","Adanced Spanish Honors in E302")
  676.       answers()
  677.     elif question=="a":
  678.       a_day("Chemistry in MSC318","The New Testament in H301","Homeroom in MSC318","Geometry Honors in H305","Video Production in MSC016","Follow Junior/Senior Lunch","English in E403","Adanced Spanish Honors in E302")
  679.       answers()
  680.     elif question=="B":
  681.       b_day("Chemistry in MSC318","Chemistry in MSC318","Academic Support","The New Testament in H301","CS: Programming in  M208","Follow Junior/Senior Lunch","Christian Service Sophmore Seminar in H003","English in E403")
  682.       answers()
  683.     elif question=="b":
  684.       b_day("Chemistry in MSC318","Chemistry in MSC318","Academic Support","The New Testament in H301","CS: Programming in  M208","Follow Junior/Senior Lunch","Christian Service Sophmore Seminar in H003","English in E403")
  685.       answers()
  686.     elif question=="C":
  687.       c_day("Adanced Spanish Honors in E302","Sophmore Group Guidance in H306","Activites","Chemistry in MSC318","Geometry Honors in H305","Follow Freshmen/Sophs Lunch","CS: Programming in  M208","Free Period")
  688.       answers()
  689.     elif question=="c":
  690.       c_day("Adanced Spanish Honors in E302","Sophmore Group Guidance in H306","Activites","Chemistry in MSC318","Geometry Honors in H305","Follow Freshmen/Sophs Lunch","CS: Programming in  M208","Free Period")
  691.       answers()
  692.     elif question=="D":
  693.       d_day("English in E403","Adanced Spanish Honors in E302","Academic Support","Free Period","The New Testament in H301","Follow Freshmen/Sophs Lunch","Geometry Honors in H305","CS: Programming in  M208")
  694.       answers()
  695.     elif question=="d":
  696.       d_day("English in E403","Adanced Spanish Honors in E302","Academic Support","Free Period","The New Testament in H301","Follow Freshmen/Sophs Lunch","Geometry Honors in H305","CS: Programming in  M208")
  697.       answers()
  698.     elif question=="E":
  699.       e_day("Video Production in MSC016","English in E403","Activites","Adanced Spanish Honors in E302","Chemistry in MSC318","Follow Freshmen/Sophs Lunch","The New Testament in H301","Geometry Honors in H305")
  700.       answers()
  701.     elif question=="e":
  702.       e_day("Video Production in MSC016","English in E403","Activites","Adanced Spanish Honors in E302","Chemistry in MSC318","Follow Freshmen/Sophs Lunch","The New Testament in H301","Geometry Honors in H305")
  703.       answers()
  704.     elif question=="F":
  705.       f_day("CS: Programming in  M208","Free Period","Homeroom in MSC318/Academic Support","English in E403","Free Period","Follow Freshmen/Sophs Lunch","Chemistry in MSC318","The New Testament in H301")
  706.       answers()
  707.     elif question=="f":
  708.       f_day("CS: Programming in  M208","Free Period","Homeroom in MSC318/Academic Support","English in E403","Free Period","Follow Freshmen/Sophs Lunch","Chemistry in MSC318","The New Testament in H301")
  709.       answers()
  710.     elif question=="G":
  711.       g_day("Geometry Honors in H305"," CS: Programming in  M208","Assemlies","Video Production in MSC016"," Adanced Spanish Honors in E302","Follow Freshmen/Sophs Lunch","Free Period","Chemistry in MSC318")
  712.       answers()
  713.     elif question=="g":
  714.       g_day("Geometry Honors in H305"," CS: Programming in  M208","Assemlies","Video Production in MSC016"," Adanced Spanish Honors in E302","Follow Freshmen/Sophs Lunch","Free Period","Chemistry in MSC318")
  715.       answers()
  716.     elif question=="H":
  717.       h_day("The New Testament in H301","Geometry Honors in H305","Academic Support","CS: Programming in  M208"," English in E403","Follow Freshmen/Sophs Lunch","Adanced Spanish Honors in E302","Free Period")
  718.       answers()
  719.     elif question=="h":
  720.       h_day("The New Testament in H301","Geometry Honors in H305","Academic Support","CS: Programming in  M208"," English in E403","Follow Freshmen/Sophs Lunch","Adanced Spanish Honors in E302","Free Period")
  721.       answers()
  722.     elif question=="0":
  723.       desktop_screen()
  724.     elif question == "ctrl alt delete":
  725.       options()
  726.     else:
  727.       print "Try again..."
  728.       print (50*'=')
  729.       questions()
  730.   questions()    
  731.   print ''
  732.  
  733. def desktop_screen(): #This is the function that runs the desktop
  734.   print "=" * 80
  735.   print "Choose corresponding number:"
  736.   print "1. Find My Element"
  737.   print "2. SheduleMe"
  738.   print "3. Start Button"
  739.   choice=raw_input()
  740.   if choice=="1":
  741.     element()
  742.   elif choice=="2":
  743.     sheduleme()
  744.   elif choice=="3":
  745.     options()
  746.   elif element == "ctrl alt delete":
  747.     options()
  748.   else:
  749.     print "Try again."
  750.     desktop_screen()
  751.  
  752. def password():  #This is the function to run the progarm for the password
  753.   print "Password:",
  754.   answer=raw_input()
  755.   if answer=="123":
  756.     desktop_screen()
  757.   else:
  758.     password()
  759.  
  760. def sign_in(): # defines a function that will be used to imput a username
  761.   user=raw_input("Username: ")
  762.   if user=="Max":
  763.     password()
  764.   elif user=="marvin":
  765.     password()
  766.   else:
  767.     print "Try again."
  768.     sign_in()
  769.  
  770. def startup(): # defines a function that will be used to imput a username
  771.   print "(Press start button(type \"on\") to turn on computer)"
  772.   start=raw_input()
  773.   if start=="on":
  774.     bootup()
  775.     sign_in()
  776.   elif start=="On":
  777.     bootup()
  778.     sign_in()
  779.   else:
  780.     startup()
  781. startup()
Add Comment
Please, Sign In to add comment