Write a command-line tool that reads a grid from stdin or a file and computes the shortest path from a start…
Write a command-line tool that reads a grid from stdin or a file and computes the shortest path from a start…: a task in TermGrade Environments: 1,004 executable Linux tasks (Harbor dataset). Input format: - First line: two integers rows cols (1 ≤ rows, cols ≤ 1000) - Second line: four integers sr…
The task
**Input format:** - First line: two integers `rows cols` (1 ≤ rows, cols ≤ 1000) - Second line: four integers `sr sc gr gc` (0-indexed start and goal coordinates) - Next `rows` lines: each has `cols` space-separated integers representing cell costs (non-negative, <10000). The start and goal cells are always…
Part of ai-and/termgrade-environments.