https://www.acmicpc.net/problem/14226코드#include #include using namespace std;#define MAX 1001#define FASTIO ios::sync_with_stdio(false); cin.tie(NULL);int s;bool visited[MAX][MAX]; struct d { int cnt; int clip; int time; };void bfs() { queue q; q.push({ 1, 0, 0 }); visited[1][0] = 1; while (!q.empty()) { int cnt = q.front().cnt; int clip = q.front().clip; ..