Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- # Futurelearn RPi course: Python 102 - Week 1 Function
- def tri_area():
- height = int(input("What is the height of the triangle> "))
- width = int(input("What is the width of the triangle> "))
- area = 0.5 * width * height
- print("The area of your triangle is " + str(area))
- tri_area()
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement