Reachable
CF1320D Reachable Strings
110和011互相转化,相当于就是0在连续两个1的情况下,移动两个位置 能够发现,0的位置的奇偶不会改变,且很多个0之间的相对位置不会改变 猜想考虑这个答案只跟0的奇偶性有关,下面小证一下:(注意下面所说的“奇偶”指的是两个字符串的分别第一个字母为奇数时的奇偶,不是总字符串的奇偶) 若0的相对位置奇 ......
[LeetCode] 2849. Determine if a Cell Is Reachable at a Given Time
You are given four integers sx, sy, fx, fy, and a non-negative integer t. In an infinite 2D grid, you start at the cell (sx, sy). Each second, you mus ......