title: How to check if string contains both uppercase and lowercase characters
body: <p>I need to validate password entered by user and check if the password contains at least one uppercase and one lowercase char in Dart.</p>
  <p>I wrote this String extension:</p>
  <pre class="lang-dart prettyprint-override"><code>extension StringValidators on String {
    bool containsUppercase() {
      // What code should be here?
    }
  
    bool containsLowercase() {
      // What code should be here?
    }
  }
  </code></pre>
  <p>And use it like this:</p>
  <pre class="lang-dart prettyprint-override"><code>final text = passwordTextController.text;
  final isValid = text.containsUppercase() &amp;&amp; text.containsLowercase();
  </code></pre>
  <p>Is there any regexp for this purpose? Or it should be plain algorithm? Please help me to find out the elegant way. Thanks!</p>