public static Field randomReachableField(Field from, HashMap<Field, ArrayList<Object>> conflictingHashMap, ArrayList<Field> shouldGetCleared) {
		
		LinkedList<Field> frontier = new LinkedList<Field>();
		
		frontier.add(from);
		ArrayList<Field> closedSet = new ArrayList<Field>();

		
		Field currentField = frontier.poll();
		closedSet.add(currentField);
				
		while(currentField != null){
			
			for (Field neighbour : currentField.neighbors) {
				if(neighbour != null && !closedSet.contains(neighbour) &&  
						(!conflictingHashMap.containsKey(neighbour) || 
						(conflictingHashMap.containsKey(neighbour) && conflictingHashMap.get(neighbour).contains(from)))){
					frontier.add(neighbour);
					closedSet.add(neighbour);
				}
			}
			
			currentField = frontier.poll();
		}
		Random rand = new Random();
		return closedSet.get(rand.nextInt(closedSet.size()));
	}