public boolean legalMove(Move m) {
		return ( // the player must exist
		(m.player.equals("red") || m.player.equals("blue")) &&
		// it must be his turn
				(m.player.equals(turn)) &&
				// the player must own the piece he wants to move
				(owner(m.begin) != null) && (owner(m.begin).equals(m.player)) &&
				// the goal position must be empty
				(owner(m.end) == null) &&
		// the goal position can be reached with a step or a jump

		(m.begin.neighbour(m.end) || 
		 m.begin.jumpNeighbour(m.end)));
    }