This application generates on board 20 x 20 random fields where water is spilt. Then counts the number of pools - fields with spilt water that touch each other, prints their number and determines which pool is the largest one (shown highlighted).

In case of more pools with the same maximal size that one with the lowest number is highlighted. Isolated fields are removed from board.

1222
13322
2244
244
25644
2564
7728
7228
2
99
101099
1199
111213
11121213
14121212
1414151616
1516
171717
1718192021
18192021

Number of pools: 21
The largest pool consists of 14 fields being marked with number 2.