title: Calculating the perimeter of any triangle [python 3]
body: <p>I am following an online course on python, and am stuck on this activity:</p>
  
  <blockquote>
    <p>Assume distance2D(x1, y1, x2, y2) has already been defined. Using it, define a function trianglePerimeter(xA, yA, xB, yB, xC, yC) which calculates the perimeter of a triangle whose three points are (xA, yA), (xB, yB) and (xC, yC).</p>
  </blockquote>
  
  <p>Now distance2D is a function to calculate the distance between two points:</p>
  
  <blockquote>
    <p>Assume hypotenuse(a, b) has already been defined. Using it, define a function distance2D(x1, y1, x2, y2) which calculates the distance between the point (x1, y1) and the point (x2, y2).</p>
  </blockquote>
  
  <p>Hypotenuse is just to calculate the hypotenuse of a right-angle triangle. The site is asking me to use the distance2D function to define the trainglePerimeter function.</p>
  
  <p>The following is my code. </p>
  
  <pre><code>def trianglePerimeter(xA,yA,xB,yB,xC,yC):
      a = distance2D(xA,yA,xB,yB)
      b=distance2D(xB,yB,xC,yC)
      return a+b
  </code></pre>
  
  <p>Other than just that, I have tried altering the code, and nothing seems to work. Can someone <em>please</em> help me!</p>
  
  <p>error message i get: </p>
  
  <blockquote>
    <p>Before running your code: We defined a function distance2D. 
    Program executed without crashing.
    The grader said:
    Running trianglePerimeter(0, 0, 0, 3, 4, 0) … Error: trianglePerimeter(0, 0, 0, 3, 4, 0) has wrong value 10.0, expected 12.0</p>
  </blockquote>