title: How to print array list data using ajax?
body: <p>I am new to AJAX and JSON. I have an <code>ArrayList</code> which contains another <code>ArrayList</code> and I converted the whole array in to JSON object:</p>
  
  <pre><code>@Produces(MediaType.APPLICATION_JSON)
  public String getRecords(@QueryParam("mobile_no") String mobilenumber) {
      UserActivityDelegate delegate = new UserActivityDelegate();
      List&lt;AssessmentDTO&gt; list = delegate.getLastFiveAssessment(mobilenumber
              .trim());
      if (list.isEmpty())
          return "Sorry....You have not attended any assessment";
      else {
          System.out.println(list);
          return (new Gson()).toJson(list);
  
      }
  </code></pre>
  
  <p>Now I want to know how can I retrieve or iterate the response object in JSP using ajax?? </p>