Flood fill 算法
来源:互联网 发布:smtp服务器端口25 编辑:程序博客网 时间:2024/05/22 10:42
http://en.wikipedia.org/wiki/Flood_fill#Stack-based_recursive_implementation_.28Four-way.29
Flood-fill (node, target-color, replacement-color): 1. If target-color is equal to replacement-color, return. 2. Set Q to the empty queue. 3. Add node to the end of Q. 4. While Q is not empty: 5. Set n equal to the last element of Q. 6. Remove last element from Q. 7. If the color of n is equal to target-color: 8. Set the color of n to replacement-color. 9. Add west node to end of Q. 10. Add east node to end of Q. 11. Add north node to end of Q. 12. Add south node to end of Q. 13. Return.
0 0
- Flood fill 算法
- Flood Fill
- flood fill
- Flood Fill(漫水填充)算法
- 泛洪填充算法(Flood Fill Algorithm)
- 图像处理之泛洪填充算法(Flood Fill Algorithm)
- 基础BFS 邻接矩阵Flood fill 算法题目总结
- 走迷宫 Flood Fill
- Flood Fill Image
- Flood Fill Algorithm
- 733. Flood Fill
- Flood Fill(leetcode)
- 733. Flood Fill
- USACO The Castle(flood fill)
- Flood Fill问题及解法
- LWC 60:733. Flood Fill
- python--leetcode 733. Flood Fill
- 算法1(多邊形面积,多边形方向,Flood-Fill, Floyd-Warshall算法, 最短路問題)
- 微弱光芒暖人心
- 如何用各种编程语言杀死一条龙
- “关于”对话框
- poj 3233 Matrix Power Series nyoj 299
- 雾霾来了
- Flood fill 算法
- 列表界面Iphone式平滑效果实现
- 阅江楼游记
- jclasslib修改class文件内容
- Hadoop初探之Hadoop生态圈
- 我的贝贝
- 如何在 javascript / js 中 建立一个map
- 秋游南京阅江楼
- change log 的概念