Answer:
Program written in Python
def KEfunction(mass,velocity):
KE = 0.5 * mass * velocity**2
print("Kinetic Energy: "+str(KE))
def momentum(mass,velocity):
P= mass * velocity
print("Momentum: "+str(P))
Mass = float(input("Mass (kg): "))
Velocity = float(input("Velocity (m/s): "))
KEfunction(Mass,Velocity)
momentum(Mass,Velocity)
Step-by-step explanation:
This line defines the kinetic energy function
def KEfunction(mass,velocity):
This line calculates the kinetic energy
KE = 0.5 * mass * velocity**2
This line prints the kinetic energy
print("Kinetic Energy: "+str(KE))
This line defines the momentum function
def momentum(mass,velocity):
This line calculates the momentum
P= mass * velocity
This line prints the momentum
print("Momentum: "+str(P))
The main method begine here
This line prompts user for mass
Mass = float(input("Mass (kg): "))
This line prompts user for velocity
Velocity = float(input("Velocity (m/s): "))
This line calls the kinetic function
KEfunction(Mass,Velocity)
This line calls the momentum function
momentum(Mass,Velocity)