title: "The left-hand side of an assignment must be a variable" problem with charAt
body: <pre><code>private String kNow(String state, String guess) {
          for (int i = 0; i &lt; word.length(); i++) {
              if (guess.equals(word.charAt(i))) {
                  state.charAt(i) = word.charAt(i);
              }
          }
          return state;
      }
  </code></pre>
  
  <p>state.charAt(i) part points the problem in the title. 
  How can I solve the problem, if my approach is not completely wrong.</p>