This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <iostream> | |
#include <string.h> | |
#include <algorithm> | |
using namespace std; | |
int n=0, k=0; | |
int map[20][20]; | |
int arr[20]; | |
int ans = 0; | |
bool visited[20]; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <iostream> | |
#include <vector> | |
using namespace std; | |
vector<int> v[10010]; | |
int n=0; //노드의 갯수 | |
bool visited[10010]; | |
void dfs(int curr){ | |
/*현재 노드의 edge를 방문하기 전 */ | |
visited[curr] = true; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <iostream> | |
#include <vector> | |
using namespace std; | |
vector<int> v[10010]; | |
int n=0; //노드의 갯수 | |
bool visited[10010]; | |
int ans = 0; | |
void dfs(int curr){ | |
/*현재 노드의 edge를 방문하기 전 */ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <iostream> | |
#include <vector> | |
using namespace std; | |
vector<int> v[10010]; | |
int n=0; //노드의 갯수 | |
bool visited[10010]; | |
int dfs(int curr){ | |
/*현재 노드의 edge를 방문하기 전 */ | |
visited[curr] = true; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <iostream> | |
#include <algorithm> | |
using namespace std; | |
int n=0; | |
int input[10]; | |
int arr[10]; | |
int ans =0; | |
bool visited[10]; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <iostream> | |
#include <algorithm> | |
using namespace std; | |
int n=0, ans =1000000000; | |
int input[20][2]; | |
void recur(int depth, int choice, int x, int y){ | |
if(depth != 0){ | |
ans = ans > abs(x-y) ? abs(x-y) : ans; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* | |
1시간 16분 | |
*/ | |
#include <iostream> | |
#include <algorithm> | |
#include <string> | |
using namespace std; | |
int n = 0, k=0; | |
int ans = 0; | |
string input[55]; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <iostream> | |
#include <string.h> | |
using namespace std; | |
string map[5]; | |
int ans =0; | |
int dx[4] = {0,0,1,-1}; | |
int dy[4] = {1,-1,0,0}; | |
bool selected[5][5]; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <iostream> | |
#include <string.h> | |
using namespace std; | |
int map[9][9]; | |
bool flag; | |
bool visited[10]; | |
bool check(int x, int y){ | |
memset(visited,false, sizeof(visited)); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <iostream> | |
#include <string.h> | |
#include <vector> | |
using namespace std; | |
int n=0, ans=0; | |
int tans = 0; | |
char input; | |
vector<int> f[50]; |