Gallery
Athletics Scotland with starter code
Share
Explore
Athletics Scotland with starter code

icon picker
Python Starter Code

Copy and paste the code below into your main.py file before you begin the task.

# Athletics Scotland
# ==================
import time

# display title and sports on offer
print('\n')
print(' ATHLETICS SCOTLAND ')
print('====================')
print('\n')
print('Sports on offer to watch:')
print('- 100m Sprint')
print('- Relay')
print('- Hurdles')
print('- Long Jump')
print('\n\n')

# get sport from user
sport = input('Which sport are you going to see: ')
# get number of tickets from user
numberOfTickets = int(input('Number of Tickets: '))

print('\n')
print('Processing order...')
# pauses screen for 3 seconds
time.sleep(3)
# clears screen
print('\033[H\033[2J')
print('\n\n')

# get user name
fullName = input('Enter next full name: ')
# display ticket details
print('\n')
print('-------------------------------------')
print('Athletics Scotland - Grand Prix Event')
print('Sport: ' + sport)
print('Full name: ' + fullName)
print('-------------------------------------')
print('\n')
Share
 
Want to print your doc?
This is not the way.
Try clicking the ⋯ next to your doc name or using a keyboard shortcut (
CtrlP
) instead.