Skip to content

Commit

Permalink
Add files via upload
Browse files Browse the repository at this point in the history
  • Loading branch information
KENEW authored Jan 18, 2021
1 parent 8246ee0 commit 6adac1b
Showing 1 changed file with 53 additions and 0 deletions.
53 changes: 53 additions & 0 deletions 11724_연결_요소의_개수.cpp
Original file line number Diff line number Diff line change
@@ -0,0 +1,53 @@
//#include<iostream>
//#include<vector>
//#define MAX 1001
//using namespace std;
//
//int N, M;
//vector<int> arr[MAX];
//bool visited[MAX];
//int result = 0;
//
//void DFS(int index)
//{
// if (visited[index] == false)
// {
// visited[index] = 1;
// }
// else
// {
// return;
// }
// for (int i = 0; i < arr[index].size(); i++)
// {
// int next = arr[index][i];
// DFS(next);
// }
//}
//
//int main(void)
//{
// cin >> N >> M;
//
// for(int i = 0; i < M; i++)
// {
// int u, v;
// cin >> u >> v;
//
// arr[u].push_back(v);
// arr[v].push_back(u);
// }
//
// for (int i = 1; i <= N; i++)
// {
// if (visited[i] == 0)
// {
// result++;
// DFS(i);
// }
// }
//
// cout << result;
// return 0;
//}
//

0 comments on commit 6adac1b

Please sign in to comment.