title: error: incompatible types: char cannot be converted to String - Java
body: <p>This is just a part of my code that I have problem troubleshooting. </p>
  
  <pre><code>static int checkConcat(String number) {
          TreeSet&lt;Integer&gt; a = new TreeSet&lt;Integer&gt;();
          for(int i=0; i&lt;number.length(); i++) {
              a.add(Integer.parseInt(number.charAt(i)));
          }
  }
  </code></pre>
  
  <p>The error that I'm getting is :</p>
  
  <blockquote>
    <p>error: incompatible types: char cannot be converted to String</p>
  </blockquote>
  
  <p>What's wrong with the code, and how can I solve it in this context?</p>