static Direction getDir(String s) {
        if(s.equalsIgnoreCase("r")) return RIGHT;
        if(s.equalsIgnoreCase("d")) return DOWN;
        if(s.equalsIgnoreCase("l")) return LEFT;
        if(s.equalsIgnoreCase("u")) return UP;
        return null;
    }