Tuesday 3 March 2020

Using Python 3

Today i learnt how to independently draw a flow chart, I also learnt how to put in programmes to do mathematical equations.
NumA = input("please enter the first number.")
NumB = input("please enter the second number.")
Add = int(NumA) + int(NumB)
print ("Addition: " + str(Add))
Sub = int(NumA) - int(NumB)
print("Subtraction: " + str(Sub))
Mul = int(NumA) * int(NumB)
print("Multiplication: " + str(Mul))
Div = int(NumA) / int(NumB)
print("Division: " + str(Div))
      
After that, I tried to create a program that calculated the circumference of a circle if a radius was entered into the program (it isn't finished).
NumA = input("please enter the radius of a circle")
Diameter = int(NumA) * 2
print ("Multiplication: " + str(Diameter))
Cir=

No comments:

Post a Comment