title: How to print an array to an input field in jsp?
body: <p>An array of integers <code>fibSequence</code> is passed over to a jsp page <code>result</code> using a redirect which is retrieved like this: <code>&lt;%String[] fibSequence = request.getParameterValues("fibSequence");%&gt;</code>.
  But when I set the input field's value to the fibSequence array I get a memory address of the array and not the integer values stored in the array:</p>
  
  <p><code>[Ljava.lang.String;@678f482d</code></p>
  
  <p><img src="https://i.stack.imgur.com/GL0U7.png" alt="mem address"></p>
  
  <p>This is how the array is being output to the text box:</p>
  
  <p><code>&lt;input type="text" name="fibNum" value="&lt;%=fibSequence%&gt;" size="40px" style="font-size:30pt;height:60px"&gt;</code></p>
  
  <p>and also I've tried like this from the below answer but the output is still the same:</p>
  
  <p><code>&lt;input type="text" name="fibNum" value="&lt;%=java.util.Arrays.deepToString(fibSequence)%&gt;" size="40px" style="font-size:30pt;height:60px"&gt;</code></p>
  
  <p>Does anyone know how the contents of the array can be output to a textbox in jsp?</p>
  
  <p>I have tried to use the Arrays.toString method to print out the values, but I get an error <code>Arrays</code> cannot be resolved:</p>
  
  <p><code>&lt;%=Arrays.toString(fibSequence)%&gt;</code></p>