static void next_move(int posr, int posc, String[] board) {
        char[][] chars = new char[board.length][board[0].length()];
        for (int i = 0; i < board.length; i++) {
            chars[i] = board[i].toCharArray();
        }

        String ret = null;
        if (chars[posr][posc] == 'd') {
            ret = "CLEAN";
            chars[posr][posc] = '-';
            board[posr] = new String(chars[posr]);
        } else {
            for (int i = 1; i < (board.length - 1) * 2; i++) {
                int[] next = findNextD(posr, posc, chars, i);

                if (next != null) {
                    if (next[0] < posr) {
                        ret = "UP";
                    } else if (next[0] > posr) {
                        ret = "DOWN";
                    } else {
                        if (next[1] < posc) {
                            ret = "LEFT";
                        } else if (next[1] > posc) {
                            ret = "RIGHT";
                        }
                    }

                    break;
                }
            }
        }
        System.out.println(ret);
    }