码迷,mamicode.com
首页 >  
搜索关键字:surrounded    ( 192个结果
LeetCode-130-Surrounded Regions
算法描述: Given a 2D board containing 'X' and 'O' (the letter O), capture all regions surrounded by 'X'. A region is captured by flipping all 'O's into 'X ...
分类:其他好文   时间:2019-02-05 22:12:46    阅读次数:108
leetcode 200. Number of Islands
Given a 2d grid map of '1's (land) and '0's (water), count the number of islands. An island is surrounded by water and is formed by connecting adjacen ...
分类:其他好文   时间:2019-01-28 21:18:37    阅读次数:141
200. Number of Islands - Medium
Given a 2d grid map of '1's (land) and '0's (water), count the number of islands. An island is surrounded by water and is formed by connecting adjacen ...
分类:其他好文   时间:2018-11-29 20:14:39    阅读次数:137
200. Number of Islands
Given a 2d grid map of '1's (land) and '0's (water), count the number of islands. An island is surrounded by water and is formed by connecting adjacen... ...
分类:其他好文   时间:2018-11-06 11:02:41    阅读次数:112
130. Surrounded Regions
一、题目 1、审题 2、分析 给出一个二维数组,数组中只包含字符 'O'、‘X', 将数组中被 'X' 包围的 'O' 全部换成 'X'。(其中紧邻边界不算包围) 二、解答 1、思路: 方法一、 ①、将紧挨着棋盘边缘的 "O'" 或者与边缘的 "O" 连通的 “O” 全部换成 “1“; ②、将剩下的 ...
分类:其他好文   时间:2018-10-08 13:59:29    阅读次数:142
130. Surrounded Regions
Given a 2D board containing 'X' and 'O' (the letter O), capture all regions surrounded by 'X'. A region is captured by flipping all 'O's into 'X's in ... ...
分类:其他好文   时间:2018-09-20 18:46:34    阅读次数:164
[LeetCode] 130. Surrounded Regions_Medium tag: DFS
Given a 2D board containing 'X' and 'O' (the letter O), capture all regions surrounded by 'X'. A region is captured by flipping all 'O's into 'X's in ...
分类:其他好文   时间:2018-08-08 00:33:15    阅读次数:169
F - Lakes in Berland(BFS)
The map of Berland is a rectangle of the size n?×?m, which consists of cells of size 1?×?1. Each cell is either land or water. The map is surrounded b ...
分类:其他好文   时间:2018-03-29 00:16:12    阅读次数:195
[LeetCode] 200. Number of Islands 岛屿的数量
Given a 2d grid map of '1's (land) and '0's (water), count the number of islands. An island is surrounded by water and is formed by connecting adjacen ...
分类:其他好文   时间:2018-03-01 11:52:20    阅读次数:233
130. Surrounded Regions(周围区域问题 广度优先)(代码未完成!!)
Given a 2D board containing 'X' and 'O' (the letter O), capture all regions surrounded by 'X'. A region is captured by flipping all 'O's into 'X's in ...
分类:其他好文   时间:2018-02-26 23:16:37    阅读次数:192
192条   上一页 1 2 3 4 ... 20 下一页
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!