알고리즘 문제 풀이

알고리즘 문제 풀이/1DP_과제(~180615)

180524_9626_크로스워드 퍼즐

//https://www.acmicpc.net/problem/9626 #include using namespace std;char map[10][10];int main(){ int m,n; int u,l,r,d; cin >> m >> n; cin >> u >> l >> r >> d; for(int i=0; i> map[i]; } for(int i=0; i

알고리즘 문제 풀이/1DP_과제(~180615)

180523_10610_30

//https://www.acmicpc.net/problem/10610 #include #include #include #include using namespace std; int main(){ string num; cin >> num; int l=num.size(); int sum=0; bool chk=0; vector v; for(int i=0; i=0; --i) { cout

알고리즘 문제 풀이/1DP_과제(~180615)

180522_4963_섬의 개수

//https://www.acmicpc.net/problem/4963 #include #include #include using namespace std; bool map[50][50];bool visited[50][50];int cnt;int w, h;int dy[8]={-1, -1, -1, 0, 0, 1, 1, 1};int dx[8]={-1, 0, 1, -1, 1, -1, 0, 1};void bfs(int y, int x){ queue q; q.push(make_pair(y,x)); map[y][x]=0; int nowy; int nowx; while(!q.empty()){ nowy=q.front().first; nowx=q.front().second; q.pop(); for(int i=0; i> w..

알고리즘 문제 풀이/1DP_과제(~180615)

180521_9012_괄호

//https://www.acmicpc.net/problem/9012 #include #include #include using namespace std; bool vps(){ stack s; string str; cin >>str; int l=str.size(); s.push(str[0]); for(int i=1; i> tc; for(int i=0; i

bong sue
'알고리즘 문제 풀이' 카테고리의 글 목록 (7 Page)