title: String contains at least one digit
body: <p>I am trying to see whether a string contains at least a digit or a lowercase or an uppercase.</p>
  
  <p>I have written something like this:</p>
  
  <pre><code>      int combinations = 0;
        string pass = "!!!AAabas1";
  
        if (pass.matches("[0-9]")) {
            combinations = combinations + 10;
        }
  
        if (pass.matches("[a-z]")) {
            combinations =combinations + 26;
        }
  
        if (pass.matches("[A-Z]")) {
            combinations =combinations + 26;
        }
  </code></pre>
  
  <p>However I don't understand why I cannot get combinations to go to 36. They just remain at 0. What am I doing wrong?</p>