
BFS
love music.
中山大学计算机博士在读,曾就职于腾讯等公司,目前从事AI多模态大模型研究。
展开
-
PAT甲级 1076 Forwards on Weibo (30 分)BFS 图的遍历
1076 Forwards on Weibo (30 分)Weibo is known as the Chinese version of Twitter. One user on Weibo may have many followers, and may follow many other users as well. Hence a social network is formed wi...原创 2018-10-08 22:04:44 · 225 阅读 · 0 评论 -
PAT甲级 1094 The Largest Generation (25 分)BFS,树的宽度
1094 The Largest Generation (25 分)A family hierarchy is usually presented by a pedigree tree where all the nodes on the same level belong to the same generation. Your task is to find the generation ...原创 2018-11-09 22:36:59 · 162 阅读 · 0 评论 -
BFS广度优先求最少步数
参考连接:https://blog.youkuaiyun.com/baidu_23955875/article/details/46821793参考链接:https://blog.youkuaiyun.com/qq_29762941/article/details/81259789最少步数时间限制:3000 ms | 内存限制:65535 KB难度:4描述这有一个迷宫,有0~8行和0~8列:...原创 2018-07-28 12:29:29 · 669 阅读 · 0 评论 -
网易游戏面试题 推箱子
参考链接:https://blog.youkuaiyun.com/q__y__L/article/details/60875960时间限制:1秒空间限制:32768K大家一定玩过“推箱子”这个经典的游戏。具体规则就是在一个N*M的地图上,有1个玩家、1个箱子、1个目的地以及若干障碍,其余是空地。玩家可以往上下左右4个方向移动,但是不能移动出地图或者移动到障碍里去。如果往这个方向移动推到了箱子,箱子...原创 2018-07-29 13:40:59 · 1372 阅读 · 0 评论 -
1091 Acute Stroke (30 分)BFS
1091 Acute Stroke (30 分)One important factor to identify acute stroke (急性脑卒中) is the volume of the stroke core. Given the results of image analysis in which the core regions are identified in each M...原创 2018-11-08 16:42:08 · 541 阅读 · 0 评论 -
PAT甲级 1102 Invert a Binary Tree (25 分)树的遍历(bfs+dfs)
1102 Invert a Binary Tree (25 分)The following is from Max Howell @twitter:Google: 90% of our engineers use the software you wrote (Homebrew), but you can't invert a binary tree on a whiteboard so...原创 2018-11-20 18:20:59 · 183 阅读 · 0 评论