title: Learning float numbers length
body: <p>Is there any command like <code>len()</code> to measure length of float number?</p>
  <p>when I try : <code>len(a[k])</code> <em>(a[k] is the array, which gives random float numbers)</em>:</p>
  <p>there is an error like the following:</p>
  <pre><code>object of type 'float' has no len()
  </code></pre>
  <hr />
  <p>My code:</p>
  <pre><code>import random
  a=[random.uniform(10,100) for i in range (1000)]
  
  c= open(&quot;dosya.txt&quot;,&quot;w&quot;)
  c.write('X DEGER:  Y DEGER:\n')
  c.write('--------------\n')
  
  count = 0.0
  while count &lt; 99.9:
  count +=0.1
  c.write (&quot;%s\n&quot; % count)    
  
  
  c=open(&quot;dosya.txt&quot;,&quot;w&quot;)
  c.seek(37,0)
  for k in range(900):
      print a[k]
      c.write(&quot;, %.2f&quot; %(a[k]))
      c.seek(len(str(a[k])),1)    
      c.close
  </code></pre>
  <p>I want to create two columns in the file, but second loops the numbers, owerwritng on the first one.</p>
  <p>For example,</p>
  <pre><code> 0.1  38.582   
   0.2  58.214                        
   0.3  16.427  
  
                  
  </code></pre>
  <p>but the output is like:</p>
  <pre><code> 0.1 38.585
   0.3 25.420 
   0.5 47.543
  </code></pre>
  <p>As you see the float number overwriting <code>0.2</code>.</p>