Computer Science, asked by christene74, 1 month ago

write a program in python and ask the input from the user and calculate the area of a triangle.​

Answers

Answered by KesavanCSE
1

Answer:

print("Enter base")

b=int(input())

print("Enter height")

h=int(input())

print("Area of triangle is:")

print((b*h)/2)

Answered by rajbalanathasar
1

Answer:

h = float(input("Enter height of the triangle: "))

b = float(input("Enter base of the triangle: "))

area = 0.5 * b * h

print("Area of triangle = ", area)

Explanation:h = float(input("Enter height of the triangle: "))

b = float(input("Enter base of the triangle: "))

area = 0.5 * b * h

print("Area of triangle = ", area)

Similar questions