 <p><code>Scanner</code> has a <code>nextFloat()</code> for getting <code>float</code>s fashion to <code>nextInt()</code>. Just call it in its own loop:</p> <pre><code>System.out.print("Enter " + c.length + " float values: "); for(int index1 = 0; index1 &lt; c.length; index1++) { c[index1] = input.nextFloat(); } </code></pre> <p>Unfortunately, there is no <code>nextChar()</code> method, so you'd have to emulate it with <code>next(String)</code>'s variant that accepts a pattern:</p> <pre><code>System.out.print("Enter " + b.length + " char values: "); for(int index1 = 0; index1 &lt; b.length; index1++) { b[index1] = input.next(".").charAt(0); } </code></pre>