title: How do I write a function in python that calculates the coordinates of a third point on a line between a first and a second point
body: <p>Consider the following diagram as a simplified example.</p>
  
  <p><a href="https://i.stack.imgur.com/ACHoI.jpg" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/ACHoI.jpg" alt="diagram"></a></p>
  
  <p>X and Y are known for point A (0,4) and point B (4,2).</p>
  
  <p>Given X = 1, how would a python function look that can calculate Y for point C (1, #)?</p>