You will write a function that tests whether a point is on a line, another for a pair, and use them to search for the solution of a pair.
The idea. A point is on the line when . It is a solution of a pair when it is on both lines.
Your tasks.
on_line, return True when the point is on the line .is_solution, return True when the point is on both lines of the pair.found to the points with and whole numbers from to that are solutions of pair.Have you tried it?
Do the tasks in the editor first, and run the checker after each one. Its hints help when a check fails. When you are ready, compare your code with this solution.
Log in to join the discussion.
Loading…