Object-Oriented Programming · Shopify · Easy
Problem: Build a 2D Robot with Turning, Movement, and a CLI Create a robot-control system for a two-dimensional plane. The robot begins at an initial coordinate and is oriented toward one of four directions: North, East, South, or West. It must be able to turn in either direction and advance by one unit. Functional Requirements Create a Robot class, or an equivalent abstraction, that provides at least: The current position (x, y) The current direction dir ∈ {N, E, S, W}…
Checking your access…