@SuppressWarnings("unchecked")
	public Graph(int V)
	{
		this.V = V;
		E = 0;

		// create an array of bags(references to bags)
		adj = (List<Integer>[]) new LinkedList[V];

		// Initialise the bags(actually create the bags)
		for (int v = 0; v < V; v++)
			adj[v] = new LinkedList<Integer>();
	}