← Amazon questions

Minimum steps to reach target by a knight

Filed under Amazon · Also reported at Cisco

Given an N x N chessboard, a starting coordinate, and a target coordinate, find the minimum number of moves a knight needs to reach the target and return the path.

You've read your 3 free write-ups

Sign up free to keep reading. Your account opens the first 10 questions of every company.

Related Amazon questions

Collected from public candidate posts and coding forums. Updated Nov 2026.