TORONTO KIDS COMPUTER CLUB | Aurora Saturday 16:30 Python Homework 20.02.29.
17156

# Aurora Saturday 16:30 Python Homework 20.02.29.

## 05 Mar Aurora Saturday 16:30 Python Homework 20.02.29.

Question 1:

A soccer team is looking for girls from ages 10 to 12 to play on their team. Write a program to ask the user’s age and if male or female (using “m” or “f”). Display a message indicating whether the person is eligible to play on the team.

Sample Input 1:
Age: 10
Gender: f

Sample Output 1:
Welcome to the team!

Sample Input 2:
Age: 10
Gender: m

Sample Output 2:
You are not allowed to play!

Question 2:

You’re on a long car trip and arrive at a gas station. It’s 200 km to the next station. Write a program to figure out if you need to buy gas here, or if you can wait for the next station.

Input Specification:

How big is your tank, in liters?
How full is your tank (in percent—for example, half full = 50)?
How many km per liter does your car get?

Output Specification:
should look something like this:

You can go another …… km
The next gas station is 200 km away
You can wait for the next station or You have buy gas here

Input Sample 1:
Size of tank: 60
percent full: 40
km per liter: 10

Output Sample 1:
You can go another 240 km
The next gas station is 200 km away
You can wait for the next station.

Input Sample 2:
Size of tank: 40
percent full: 30
km per liter: 10

Output Sample 2:
You can go another 120 km
The next gas station is 200 km away