public ICanNavigate NavigateForwardTo(int index) { ICanNavigate target = this; while (index > 0) { target = target.NavigateForward; index--; } return(target); }
public MarsRoverSquadControl(IOutput output) { _output = output; _navigationSystem = new NavigationSystem(); }
public Rover(Position startingPosition, IOutput output, ICanNavigate navigationSystem) { _output = output; _navigationSystem = navigationSystem; CurrentPosition = startingPosition; }