title: Why round(15.0)==15.0 is false?
body: <ol>
  <li>Input 4 integer <code>n</code>, <code>x[0]</code>, <code>x[1]</code>, <code>x[2]</code>
  with <code>n = a*x[0] + b*x[1] + c*x[2]</code> and <code>n&lt;=4000</code>
  find <code>maxi = a+b+c (a,b,c&gt;=0)</code></li>
  <li><p>When I ran with <code>n=3164</code>, <code>x = [42, 430, 1309]</code>. Answer must be 15. But why <code>round(15.0)==15.0</code> is false? I found it when I tried to print <code>i, j, tf, ti, maxi</code> in line 17:</p>
  
  <pre><code>x = [0, 0, 0]
  n, x[0], x[1], x[2] = map(float, raw_input().split())
  x.sort(reverse=True) #suppose x[0]&gt;=x[1]&gt;=x[2]
  maxi=0
  
  if x[2] == 1.0:
      print int(n)
  
  else:
      for i in range(int(n/x[0])+1):      #first loop to find a: a &lt;= n/x[0]
          for j in range(int(n/x[1])+1):  #second loop to find b: b &lt;= n/x[1]
              #used math to find equation I found:
              tf = float(i*(1.0-x[0]/x[2]) + j*(1.0-x[1]/x[2]) + n/x[2])
              ti = int(round(tf))
              if tf &gt; n or tf &lt;0:
                  break
  
              if ti==tf and ti &gt;= maxi: #find satisfactory value
                  maxi = ti
  
              #print i, j, ti, tf, maxi
      print maxi
  </code></pre></li>
  </ol>