Example 37: Determine the Position of a Point
Learn how to determine the position of a point in a rectangle.
We'll cover the following
Problem
Write a function that receives coordinates of the bottom left corner of a rectangle, its width, height, and coordinates of a point and determines whether the point lies inside, outside, or on the rectangle.
Level up your interview prep. Join Educative to access 80+ hands-on prep courses.