LeetCode | 547. Friend Circles 并查集
There are N studentsin a class. Some of them are friends, while some are not. Their friendship istransitive in nature. For example, if A is a direct friendof B, and B is a direct friendof C, then A is...
原创
2018-03-07 18:55:14 ·
338 阅读 ·
0 评论