当前位置:网站首页>【学习笔记】搜索
【学习笔记】搜索
2022-06-28 08:06:00 【仰望星空的蚂蚁】
搜索(x)
思维(v)
Koala and Notebook
idea 海星。
考虑拆边使得每条边的权值为 [0,9] 。
然后用类似桶排序的做法 BFS 即可。
Limak and Shooting Points
神仙题。
考虑全排列开枪顺序 。然后按照这个顺序开枪打即可。注意是倒序枚举,每一枪已知的是最终打到哪个 monster ,那么对于路径上的障碍物则用递归处理。
考试应该想不出来这么秒的方法。
这题给我们的启发是:巧妙的暴力,从不同方式切入,搜索难度差别很大。
Super Jaber
解法似乎并不容易观察到。
考察路径分为两种:
- 不经过任何 “传送门” ,相当于直接曼哈顿距离 。
- 经过某个颜色的传送门,那么我们可以枚举颜色,作为 “中转站”
只需预处理出 d p [ i ] [ x ] [ y ] dp[i][x][y] dp[i][x][y] 表示从颜色为 i i i 的任意起点出发到 ( x , y ) (x,y) (x,y) 的最短距离即可。方法是显然的。
这道题非常考验观察能力。
Playoff Restoration
idea 海星 。
meet in the middle + 暴力 + 模拟
边栏推荐
猜你喜欢

Section 9: dual core startup of zynq

Leetcode learning records

Redis master-slave structure and application scenarios

Activity隐式跳转

Configuring MySQL multi instance master-slave synchronization for Linux

2022巴黎时装周儿童单元6.19武汉站圆满落幕

Kubernetes cluster command line tool kubectl

SQL analysis (query interception analysis for SQL optimization)

Today's notes 22/1/7

Unity 获取当前物体正前方,一定角度、距离的坐标点
随机推荐
Study notes 22/1/18
三角变换公式
Image translation /transformer:ittr: unpaired image to image translation with transformers
Section VII starting principle and configuration of zynq
挖财注册开户靠谱吗?安全吗?
Ambari (VIII) --- ambari integrated impala document (valid for personal test)
Soft test -- software designer -- database design of afternoon questions
Eslint 语法监测关闭
同花顺注册开户靠谱吗?安全吗?
Devops Basics: Jenkins deployment and use (I)
Es data export CSV file
How to configure DDR3 of dm8148
How to use redis to solve concurrency problems
Section 9: dual core startup of zynq
asp. Net registration page
Explanation and application of instr() function in Oracle
Airflow2.x distributed deployment DAG execution failure log cannot be obtained normally
sql主从复制搭建
Helloword routine for ROS
Buffer pool in MySQL