Question: Example if age < ##: print ( message 1 ) else: print ( message 2 ) If age is less than ## , then results
Example
if age ##:
printmessage
else:
printmessage
If age is less than ## then results will be :
message
If age not less than ## then results will be:
message
Specifications Part a
Collect name, birthdate, and temperature from keyboard.
Calculate age from birthdate
Prevent entry if age is less than and display message why entry not
allowed.
If age over check temperature to prevent sick patrons or zombies
If temperature over patron not allowed because of fever
If temperature under zombie not allowed entry
Repeat
Example
if age ##:
printmessage
else:
if temp ##:
printmessage
else:
if temp ##:
printmessage
else:
printmessage
How To Do Part b
If age over check temperature to prevent sick patrons or zombies
If temperature over patron not allowed because of fever
If temperature under zombie not allowed entry
Change else from under if to elif
elif condition should test temperature for over and display fever
message if true
If false, elif condition should test temperature for under o and display
zombie message if true
Otherwise, display welcome message
Test program to make sure appropriate message displayed
Example
if age ##:
printmessage
elif temp ##:
printmessage
elif temp ##:
printmessage
if and elif are lined up to the same left margin
Loops
Specifications Part
Collect name, birthdate, and temperature from keyboard.
Calculate age from birthdate
Prevent entry if age is less than and display message why entry not
allowed.
If age over check temperature to prevent sick patrons or zombies
If temperature over patron not allowed because of fever
If temperature under zombie not allowed entry
Repeat
How To Do Part
Repeat
Enclose all logic from first input prompt through all conditional
statements inside of while statement
while :
If you use a variable check use
Example
repeatstatus y
while repeatstatus y:
var input
var input
var input
varintvar
var floatvar
if var ##:
printmessage
elif var ##:
printmessage
elif var ##:
printmessage
else:
printmessage
repeatstatus inputWould you like to replay?
The lower in the while line changes all entered values to lower case so
either can be entered and verified against the lower case y
Turning in you work
Name your ZIPPED file:
Your Last NameSectionPythonCapstone.py
Make sure the file is zipped or compressed before sending the file.
Then email me that file.
I will grade them promptly.
Step by Step Solution
There are 3 Steps involved in it
1 Expert Approved Answer
Step: 1 Unlock
Question Has Been Solved by an Expert!
Get step-by-step solutions from verified subject matter experts
Step: 2 Unlock
Step: 3 Unlock
