title: Binary operator '>=' cannot be applied to operands of type 'String.IndexDistance?' (aka 'Optional<Int>') and 'Int'
body: <p>in Swift 4 I'm trying to compare the length of the text of an UITextField  with a minimum length:</p>
  
  <pre><code>if textFieldPassword.text?.count &gt;= 8 {        
  }
  </code></pre>
  
  <p>but i'm getting the error</p>
  
  <pre><code>Binary operator '&gt;=' cannot be applied to operands of type 'String.IndexDistance?' (aka 'Optional&lt;Int&gt;') and 'Int'
  </code></pre>
  
  <p><br>
  Ironically it works with</p>
  
  <pre><code>textFieldPassword.text?.count == 8
  </code></pre>
  
  <p>Can somebody help me?</p>