摘要:
就是找联通块 dfs就行 class Solution { public: bool vis[1010][1010]; void dfs(vector<vector<int>>& land, int x, int y, int& cnt) { cnt++; int len1 = land.size( 阅读全文
摘要:
用list模拟的 class Solution { public: list<int> l; int findTheWinner(int n, int k) { for(int i = 1; i <= n; i++) l.push_back(i); int cnt = 0; list<int>::i 阅读全文