SHARE
TWEET

Untitled

a guest Jan 27th, 2020 72 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. from math import *
  2.  
  3. def magnitude(x1, y1, x2, y2):
  4.     return sqrt((x2-x1)**2 + (y2-y1)**2)
  5.  
  6. def area3(x1, y1, x2, y2, x3, y3):
  7.     magnitude(x1,y1,x2,y2)
  8.     return a
  9.     magnitude(x2,y2,x3,y3)
  10.     return b
  11.     magnitude(x3,y3,x1,y1)
  12.     return c
  13.     herons_formula(a,b,c)
  14.     return herons_formula(a,b,c)
  15.  
  16.  
  17.  
  18. # Don't need to modify the following function
  19. def herons_formula(a, b, c):
  20.     s = (a + b + c) / 2
  21.     return sqrt(s * (s - a) * (s - b) * (s - c))
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
Top