随笔分类 -  BFS

摘要:You are a hiker preparing for an upcoming hike. You are given heights, a 2D array of size rows x columns, where heights[row][col] represents the heigh 阅读全文
posted @ 2021-07-05 07:23 北叶青藤 阅读(56) 评论(0) 推荐(0)
摘要:There is a ball in a maze with empty spaces and walls. The ball can go through empty spaces by rolling up, down, left or right, but it won't stop roll 阅读全文
posted @ 2019-08-13 12:34 北叶青藤 阅读(151) 评论(0) 推荐(0)
摘要:Let's play the minesweeper game (Wikipedia, online game)! You are given a 2D char matrix representing the game board. 'M' represents an unrevealed min 阅读全文
posted @ 2019-08-08 14:41 北叶青藤 阅读(702) 评论(0) 推荐(0)
摘要:You want to build a house on an empty land which reaches all buildings in the shortest amount of distance. You can only move up, down, left and right. 阅读全文
posted @ 2019-07-29 03:11 北叶青藤 阅读(279) 评论(0) 推荐(0)