title: Convert String to Integer ArrayList Java
body: <p>So the string is like this:</p>
  
  <pre><code>String favs = "[36, 40, 16]"
  </code></pre>
  
  <p>How can I save these values to the arraylist:</p>
  
  <pre><code>List&lt;Integer&gt; favs = new ArrayList&lt;&gt;();
  </code></pre>