# [ ] review and run example
print("3 + 5 =",3 + 5)
print("3 + 5 - 9 =", 3 + 5 - 9)
print("48/9 =", 48/9)
print("5*5 =", 5*5)
print("(14 - 8)*(19/4) =", (14 - 8)*(19/4))
# [ ] review and run example - 'million_maker'
def million_maker():
make_big = input("enter a non-decimal number you wish were bigger: ")
return int(make_big)*1000000
print("Now you have", million_maker())
# [ ] print the result of subtracting 15 from 43
print(43-15)
28
# [ ] print the result of multiplying 15 and 43
print(15*43)
645
# [ ] print the result of dividing 156 by 12
print(156/12)
13.0
# [ ] print the result of dividing 21 by 0.5
print(21/.5)
42.0
# [ ] print the result of adding 111 plus 84 and then subtracting 45
print(111+84-45)
print(84-45+111)
150
150
# [ ] print the result of adding 21 and 4 and then multiplying that sum by 4
print((21+4)*4)
100
# [ ] create and test multiply() function
def multiply():
num1=input("Enter a whole number:")
num2=input("Enter a whole number:")
print(str(int(num1)*int(num2)))
multiply()
64
# [ ] create improved multiply() function and test with /, no argument, and an invalid operator ($)
def multiply(operator):
num1=input("Enter a whole number:")
num2=input("Enter a whole number:")
if operator=="*":
equation=str(int(num1)*(int(num2)))
print(equation)
elif operator=="/":
equation=str(int(num1)/(int(num2)))
print(equation)
else:
equation=("Invalid Operator")
return equation
multiply("/")
0.5
# Review, run, fix
student_name = input("enter name: ").capitalize()
if student_name.startswith("F"):
print(student_name,"Congratulations, names starting with 'F' get to go first today!")
elif student_name.startswith("G"):
print(student_name,"Congratulations, names starting with 'G' get to go second today!")
else:
print(student_name, "please wait for students with names staring with 'F' and 'G' to go first today.")
Braeden please wait for students with names staring with 'F' and 'G' to go first today.