火车上没法写,来补题了…
链接:https://ac.nowcoder.com/acm/contest/11253/I
题目描述Lovely penguins is a tiny game in which the player controls two penguins.
The game holds in two 20 × 20 20×20 20×20 grids (the left one and the right one), and each has some blocked places.
We number the grid in x t h x^{th} xth row (starting from the up), y t h y^{th} yth column (starting from the left) ( x , y ) (x,y) (x,y)
The penguins move in four directions: up, down, left, right, exactly one step once. If its way is blocked, or it reaches the border, then this movement is omitted. The player also moves the penguins in four directions, but the behavior of the two penguins is mirrored:
- L : left penguin moves to left, right penguin moves to right.
- R : left penguin moves to right, right penguin moves to left.
- U : both move upwards.
- D : both move downwards.
An operation can be omitted on one penguin but works on another.
The left penguin starts from ( 20 , 20 ) (20,20) (20,20) and wants to move to ( 1 , 20 ) (1,20) (1,20).The right penguin starts from ( 20 , 1 ) (20,1) (20,1) and wants to move to ( 1 , 1 ) (1,1) (1,1).If both penguin reach there destination, thay win the game.
Find out the shortest way to win the game.If there are many shortest ways to win, find the one with minimum lexicographical order(D
- 回坑记之或许是退役赛季?
- [LCT刷题] P1501 [国家集训队]Tree II
- [LCT刷题] P2147 洞穴勘测
- 2022-2023 ICPC Brazil Subregional Programming Contest VP记录
- [线段树套单调栈] 2019-2020 ICPC Asia Hong Kong Regional Contest H.[Hold the Line]
- The 2021 ICPC Asia Nanjing Regional Contest E.Paimon Segment Tree 区间合并线段树/维护矩阵乘法
- CF580E - Kefa and Watch 线段树维护哈希
- HDU5869 Different GCD Subarray Query 离线查询/区间贡献
- 27.CF1004F Sonya and Bitwise OR 区间合并线段树
- 26.CF1000F One Occurrence