title: I want to find the the distance between a 2D list then add it to an element
body: <p>My data is as follows:</p>
  
  <pre><code>mx_ranges1 = [ 
    (848,888),
    (806,848),
    (764,806),
    (722,764),
    (680,722),
    (638,680),
    (596,638),
    (554,596),
    (512,554),
    (470,512),
    (428,470),
    (386,428),
    (344,386),
    (302,344),
    (260,302),
    (218,260),
    (176,218),
    (134,176),
  ]
  
  a=((mx_ranges1[0][1]-mx_ranges1[0][0])/2)+(mx_ranges1[0][0])
  b=((mx_ranges1[1][1]-mx_ranges1[1][0])/2)+(mx_ranges1[1][0])
  c=((mx_ranges1[2][1]-mx_ranges1[2][0])/2)+(mx_ranges1[3][0])
  
  print(a)
  print(b)
  print(c)`
  </code></pre>
  
  <p>That way is not really efficient,  I know it can somehow be represented in a <code>for</code> loop, I just don't know how I might do it. Please give me some references since I'm new to python and programming in general. I then have another list with y which also need to take the distance then add it to the first element.</p>
  
  <p>Not sure if it can be placed directly into a single 2D array but just doing the first part should be good enough for me. I can do the rest manually.</p>