private ArrayList<Integer> generateActions(int[][] state) {
    ArrayList<Integer> result = new ArrayList<Integer>();
    int middle = x/2;
  //TODO choose random when x is even
    if (state[middle][0] == 0) {
        result.add(middle);
    }
    for (int i=1; i <= x/2; i++){
    	if(middle + i < x) {
            if (state[middle + i][0] == 0) {
                result.add(middle + i);
            }
    	}
        if(middle - i > -1) {
            if (state[middle - i][0] == 0) {
                result.add(middle - i);
            }	
    	}
    }
    return result;
    }