0 votes
427 views
in Python by (98.9k points)
edited
Python Program to Calculate the Area of a Triangle

1 Answer

0 votes
by (98.9k points)
selected by
 
Best answer
 a = float(input('Enter first side: '))
b = float(input('Enter second side: '))
 c = float(input('Enter third side: '))


s = (a + b + c) / 2


area = (s*(s-a)*(s-b)*(s-c)) ** 0.5
print('The area of the triangle is %0.2f' %area)

 

Related questions

0 votes
1 answer 107 views
0 votes
1 answer 152 views
asked Jun 11, 2022 in Python by Doubtly (98.9k points)
0 votes
1 answer 163 views
0 votes
1 answer 95 views
asked Jun 11, 2022 in Python by Doubtly (98.9k points)

Doubtly is an online community for engineering students, offering:

  • Free viva questions PDFs
  • Previous year question papers (PYQs)
  • Academic doubt solutions
  • Expert-guided solutions

Get the pro version for free by logging in!

5.7k questions

5.1k answers

108 comments

535 users

...