title: How to find an element that contains specific float number in Selenium Python?
body: <p>I would like to find an element that contains a specific float number using Selenium Python. The specific float number such as <code>1.23</code>,<code>1.002</code>,<code>2.505</code> works fine. However, I can't work it out with float numbers such as <code>1.20</code>, <code>1.300</code>, and so on. I doubted that as long as there is zero number at the end of decimal places, I failed to get it. This is because <code>1.20</code> and <code>1.300</code> end with zero at the decimal places. (Please correct me if I am wrong.)</p>
  
  <p>Here is my code:</p>
  
  <pre><code>f = open('myFile.txt', 'r')     
  i = f.read()
  driver.find_elements_by_xpath("//*[contains(text(), "+str(i)+")]").click()  
  </code></pre>
  
  <p>The <code>myFile.txt</code> contains a specific float number, it works fine when the decimal place of float number does not end with zero.</p>
  
  <p>Any helps is appreciated, thanks in advance!</p>