isValidPosition position | validX && validY = Just position
                         | otherwise        = Nothing