Lake Counting
You cannot submit for this problem because the contest is ended. You can click "Open in Problem Set" to view this problem in normal mode.
题目描述
题意:有一块N×M的土地,雨后积起了水,有水标记为‘W’,干燥为‘.’。八连通的积水被认为是连接在一起的。请求出院子里共有多少水洼?
输入
第一行为N,M(1≤N,M≤110)。
下面为N*M的土地示意图。
输出
一行,共有的水洼数。
样例
10 12
W........WW.
.WWW.....WWW
....WW...WW.
.........WW.
.........W..
..W......W..
.W.W.....WW.
W.W.W.....W.
.W.W......W.
..W.......W.
3
来源
一本通在线评测
2.22
- Status
- Done
- Rule
- ACM/ICPC
- Problem
- 6
- Start at
- 2025-2-22 19:00
- End at
- 2025-2-25 7:00
- Duration
- 60 hour(s)
- Host
- Partic.
- 4