How to parse json rest response- NoClassDefFoundError: org/json/JSONArray : I have the following uri which returns me a json response. I have tried to parse the response of get request and access to the `steps` array but it stops in the first step. Here is the code:

	 public  void getRoute() throws Exception {

	      String urlToRead="https://maps.googleapis.com/maps/api/directions/json?origin=41.43206,-81.38992&destination=Montreal&key=AIzaSyCM1NmrLIP1weQhVVUv7YjIRE5OKaVNtns";
	      
	      DefaultHttpClient httpClient = new DefaultHttpClient();
	  	  HttpGet getRequest = new HttpGet(urlToRead);
		  getRequest.addHeader("accept", "application/json");

		  HttpResponse response = httpClient.execute(getRequest);
		  String json = IOUtils.toString(response.getEntity().getContent());

		  
		  JSONArray array = new JSONArray(json);
		  for (int i = 0; i < array.length(); i++) {
			    JSONObject object = array.getJSONObject(i);
			    System.out.println(object.getJSONArray("routes"));
			}
	   }

but it complains with:

    Exception in thread "main" java.lang.NoClassDefFoundError: org/json/JSONArray