import time time_delay = 1 print("It is the Tuesday of Finals week. You hear your 9:45 alarm go off and sleepily hit snooze.") time.sleep(time_delay) print('But wait a minute! Today is the day of your final, and you have overslept! You have to make it to Broad Art Center before your exam at 10 AM.') time.sleep(time_delay) print('You must make the right decisions at the right times in order to get to and succeed at your exam.') name = input("What is your name? ") time.sleep(time_delay) while True: start = input(f"Ready to play, {name}? (Yes/No)") if start in ['Yes', 'yes', ' Yes', ' yes']: print("Great! Let's play.") while True: setting1 = input('Pre-exam breakfast, or straight out the door? (Breakfast/No Breakfast) ') if setting1 in ["Breakfast", "breakfast", " breakfast", " Breakfast"]: print("Good job! You're fueled up and headed out the door. But it's 9:50, and the clock is ticking...") time.sleep(time_delay) while True: first_choice1 = input("Do you take a Bird or walk? (Bird/Walk) ") if first_choice1 in ["Bird", "bird"]: print("You chose a Bird and head straight down Le Conte. But you spot a commotion up ahead...") time.sleep(time_delay) print("At the corner of Westwood and Le Conte, Chik-fil-a appears to be having some kind of celebration.") print("Hordes of hungry students are blocking the roads, clamoring for a chicken sandwich!") while True: chicken1 = input("Do you attempt to weave through the crowds, or do you walk? (Weave/walk) ") if chicken1 in ["Weave", "weave"]: print("As you weave through the crowds, you are forced to slow to a crawl.") time.sleep(time_delay) print("A crazed older man, thirsting for chicken, runs across your path.") time.sleep(time_delay) print("Time seems to slow as you plow into the chicken fiend, sending both him and yourself crashing to the ground.") time.sleep(time_delay) print("As he lies on the ground wailing for a chicken sandwich, you wonder if you should comfort him.") time.sleep(time_delay) while True: comfort = input('What do you do? (Comfort/Leave) ') while comfort == "Comfort" or comfort == "comfort": print("You sit on the ground with him and pat him awkwardly on the back. Slowly, he stops crying.") time.sleep(time_delay) print("As the crowds dissipate, the older man looks around at you. In the background, you hear the clock chime. Shit! You've missed your exam.") time.sleep(time_delay) print("Hey, young'un. I appreciate you staying here with me, but don't you have a final to get to?") time.sleep(time_delay) print("You sigh and tell him that you have now missed your final. He straightens up, brushes off his shirt, and shakes your hand.") time.sleep(time_delay) print("'Well,' he begins, 'you may not recognize me, but I go by Block. Gene Block.' Awed, you take a step back and kneel on the ground.") time.sleep(time_delay) print("'As a thank-you, I will give you an automatic A on your final.' He smiles indulgently.") time.sleep(time_delay) print("'Daddy Block, sir, are you even allowed to do that?'") time.sleep(time_delay) print("'I do whatever I want.'") print(f"You have won, {name}. Congratulations!") exit() if comfort == "Leave" or comfort == "leave": print("You hurry away from the scene, determined to make your exam.") time.sleep(time_delay) print("Suddenly, you hear a siren in the distance. You know it is for you. After all, you've just run over Gene Block.") time.sleep(time_delay) print("You are arrested for a hit and run. You do not make your exam.") time.sleep(time_delay) print("Better luck next time.") exit() else: print("That wasn't an option.") elif chicken1 == "Walk" or chicken1 == "walk": print("You put aside your scooter and continue pushing past the crowds.") time.sleep(time_delay) print("As you walk quickly past the hospital, you have a growing sense of unease.") time.sleep(time_delay) print("You seem to have forgotten something vital for your test.") time.sleep(time_delay) print("Your formula sheet! One notecard, front and back, with all of your notes. It's been left in the library you were studying in!") while True: formula_sheet = input("Do you go back to the library to retrieve it, or head straight to the test? (Library/Test) ") while formula_sheet == "Library" or formula_sheet == "library": print("You hurry up the hill towards Powell Library. You can feel your watch ticking down the time until your exam starts.") time.sleep(time_delay) print("You pick up the pace and rush into the library to retrieve your notecard.") time.sleep(time_delay) print("It's right on the table where you left it.") time.sleep(time_delay) print("As you leave the library, you realize you have two minutes to go until your exam!") time.sleep(time_delay) print("You all-out sprint towards Broad Art Center. You burst into the room just as the clock strikes 10.") time.sleep(time_delay) print(f"You made it! You're on time AND you've got the notecard. Congratulations, {name}!") exit() while formula_sheet == "Test" or formula_sheet == "test": print("You decide to leave the note card in the library. You haven't got the time to get it.") time.sleep(time_delay) print("As you hurry towards Broad Art Center, you try and recall the formulas that were written on the sheet...") time.sleep(time_delay) print("Some of them seem to be slipping out of your mind.") time.sleep(time_delay) print("You get to the exam with three minutes to spare. What a relief!") time.sleep(time_delay) print("Two weeks later, you get your exam results.") time.sleep(time_delay) print(f"Uh oh. You failed because you forgot everything that was on your notecard. Better luck next time, {name}.") exit() else: print("That wasn't one of the answer choices. Try again!") else: print("Not an answer choice! Try again!") while first_choice1 == "Walk" or first_choice1 == "walk": print("You'd better hurry! Walking takes a while...") time.sleep(time_delay) print("As you scramble to your final, you hear the bells begin to toll. Ding... Ding... Ding...") time.sleep(time_delay) print("It is 10 o'clock, and you are not making it to your final. Better luck next time.") exit() else: print("Try again. You only have two options.") if setting1 in ["No Breakfast", "No breakfast", "no breakfast"]: print('You gotta do what you gotta do. You have saved some time, but better hurry!') time.sleep(time_delay) while True: first_choice2 = input("Do you take a Bird or walk? (Bird/Walk) ") if first_choice2 == "Bird" or first_choice2 == "bird": print("Good choice! Walking would be slow.") time.sleep(time_delay) print("As you leave your apartment, you hear a commotion up ahead and decide it's best to avoid it.") time.sleep(time_delay) print("Instead, you head down Strathmore and onto Bruin Walk.") time.sleep(time_delay) print("As you arrive in Bruin Plaza, the crowds of people force you to end your Bird ride.") time.sleep(time_delay) print("But oh no! Someone is coming your way!") time.sleep(time_delay) print("'HEY, BIG MAN! LEMME ASK YOU A QUESTION!'") time.sleep(time_delay) print("It's Andre! And he wants to ask you a question!") while True: andre = input("What do you say to him? (No thanks/Sure/Fuck off)") while andre == "No thanks": print("Andre looks disappointed, but he moves on to the next person.") time.sleep(time_delay) print("As you pass the UCLA store, you feel a growing sense of unease.") time.sleep(time_delay) print("You seem to have forgotten something vital for your test.") time.sleep(time_delay) print("Your formula sheet! One notecard, front and back, with all of your notes. It's been left in the library you were studying in!") formula_sheet = input("Do you go back to the library to retrieve it, or head straight to the test? (Library/Test) ") while True: while formula_sheet == "Library" or formula_sheet == "library": print("You hurry up the hill towards Powell Library. You can feel your watch ticking down the time until your exam starts.") time.sleep(time_delay) print("You pick up the pace and rush into the library to retrieve your notecard.") time.sleep(time_delay) print("It's right on the table where you left it.") time.sleep(time_delay) print("As you leave the library, you realize you have two minutes to go until your exam!") time.sleep(time_delay) print("You all-out sprint towards Broad Art Center. You burst into the room just as the clock strikes 10.") time.sleep(time_delay) print(f"You made it! You're on time AND you've got the notecard. Congratulations,{name}") exit() while formula_sheet == "Test" or formula_sheet == "test": print("You decide to leave the note card in the library. You haven't got the time to get it.") time.sleep(time_delay) print("As you hurry towards Broad Art Center, you try and recall the formulas that were written on the sheet...") time.sleep(time_delay) print("Some of them seem to be slipping out of your mind.") time.sleep(time_delay) print("You get to the exam with three minutes to spare. What a relief!") time.sleep(time_delay) print("Two weeks later, you get your exam results.") time.sleep(time_delay) print(f"Uh oh. You failed because you forgot everything that was on your notecard. Better luck next time,{name}") exit() else: print("That wasn't one of the answer choices. Better luck next time.") if andre == "Sure": print("You quickly realize that was a mistake.") time.sleep(time_delay) print("Somehow, Andre gets you to pay him $100 and buy him a burger at In-N-Out.") time.sleep(time_delay) print("By the time that's over, it's noon and you've missed your test.") exit() if andre == "Fuck off": print("Andre starts to look sad. He bursts into tears on Bruin Walk and you try to comfort him.") time.sleep(time_delay) print("'You know', he sniffles, 'that wasn't a kind thing to say.'") time.sleep(time_delay) print("You miss your test.") exit() else: print("That wasn't one of the options. Try again.") elif first_choice2 in ["Walk", "walk"]: print("You'd better hurry! Walking takes a while...") time.sleep(time_delay) print("As you scramble to your final, you hear the bells begin to toll. Ding... Ding... Ding...") time.sleep(time_delay) print("It is 10 o'clock, and you are not making it to your final. Better luck next time.") exit() else: print("Try again. You only have two options.") else: print("That wasn't one of the options.") if start in ["No","no"]: print("Whenever you're ready, then!") exit() else: print("That wasn't an answer choice.")
Run
Reset
Share
Import
Link
Embed
Language▼
English
中文
Python Fiddle
Python Cloud IDE
Follow @python_fiddle
Browser Version Not Supported
Due to Python Fiddle's reliance on advanced JavaScript techniques, older browsers might have problems running it correctly. Please download the latest version of your favourite browser.
Chrome 10+
Firefox 4+
Safari 5+
IE 10+
Let me try anyway!
url:
Go
Python Snippet
Stackoverflow Question