List<Map<String, Object>> list = new ArrayList<Map<String, Object>>(); for (int j = 1; j < 3; j++) { Map<String, Object> main = new LinkedHashMap<String, Object>(); main.put("show_1", "shou_1_" + j); List<Map<String, Object>> list2 = new ArrayList<Map<String, Object>>(); for (int x = 1; x < 3; x++) { Map<String, Object> main2 = new LinkedHashMap<String, Object>(); main2.put("show_2", "shou_2_" + x); List<Map<String, Object>> list3 = new ArrayList<Map<String, Object>>(); for (int k = 1; k < 3; k++) { Map<String, Object> main3 = new LinkedHashMap<String, Object>(); main3.put("show_3", "show_3_" + k); list3.add(main3); } main2.put("content", list3); list2.add(main2); } main.put("content", list2); list.add(main); } pageContext.setAttribute("list", list);