title: Python xml - how to loop through <tbody> to get data
body: <p>I have added an snippet of the html i wish to scrape.</p>
  
  <p>I would like to go through each row (tbody) and scrape the relevant data using xml.</p>
  
  <p>the xss for each row can be found by the following:</p>
  
  <pre><code>//*[@id="re_"]/table/tbody
  </code></pre>
  
  <p>but im unsure how to set it up in python to loop through each tbody? there is not set number for the tbody rows so could range from any number.
  eg.</p>
  
  <pre><code> for each tbody:   
        ...get data
  </code></pre>
  
  <p>below is the HTML page </p>
  
  <p><a href="http://www.racingpost.com/horses/result_home.sd?race_id=651402&amp;r_date=2016-06-07&amp;popup=yes#results_top_tabs=re_&amp;results_bottom_tabs=ANALYSIS" rel="nofollow">http://www.racingpost.com/horses/result_home.sd?race_id=651402&amp;r_date=2016-06-07&amp;popup=yes#results_top_tabs=re_&amp;results_bottom_tabs=ANALYSIS</a></p>