In my servlet I am creating a list key-value pairs with the help of a Map
Map map=new HashMap();  
map.put("1", "john");  
map.put("2", "cris");  
map.put("3","patrik");  
JSONObject jsonMap=new JSONObject(map);  
out.print(jsonMap);  
I am calling the above servlet through ajax. I want to know how can I print all the key-value pairs in my javascript(with and without using jquery) without knowing the key values?
Any other idea how can I get both key-value pairs from servlet in javascript using ajax ?
Thanks
 
     
     
    