# | 제출 시각 | 아이디 | 문제 | 언어 | 결과 | 실행 시간 | 메모리 |
---|---|---|---|---|---|---|---|
148302 | 2019-08-31T23:25:15 Z | mahmoudbadawy(#3737, mahmoudbadawy) | 체스판 네모네모로직 (FXCUP4_nonogram) | C++17 | 6 ms | 512 KB |
#include "nonogram.h" #include <bits/stdc++.h> using namespace std; std::vector<std::vector<int> > SolveNonogram(int n, int m, std::vector<std::vector<int> > Rclue, std::vector<std::vector<int> > Cclue) { vector<vector<int> > v(n,vector<int>(m,0)); for(int i=0;i<n;i++) for(int j=0;j<m;j++) v[i][j]=((i+j)%2==0?1:0); for(int i=0;i<n;i+=2) { int cur=0; for(int j=0;j<Rclue[i].size();j++) { //cout << i << ": " << Rclue[i][j] << endl; int en=cur+Rclue[i][j]; for(;cur<en;cur++) v[i][cur]=1; cur++; } //cout << endl; } for(int i=0;i<m;i+=2) { int cur=0; for(int j=0;j<Cclue[i].size();j++) { int en=cur+Cclue[i][j]; for(;cur<en;cur++) v[cur][i]=1; cur++; } } return v; }
Compilation message
# | 결과 | 실행 시간 | 메모리 | Grader output |
---|---|---|---|---|
1 | Correct | 6 ms | 512 KB | Output is correct |
2 | Correct | 5 ms | 384 KB | Output is correct |
3 | Correct | 6 ms | 384 KB | Output is correct |
4 | Correct | 6 ms | 384 KB | Output is correct |
5 | Correct | 5 ms | 384 KB | Output is correct |
# | 결과 | 실행 시간 | 메모리 | Grader output |
---|---|---|---|---|
1 | Correct | 6 ms | 512 KB | Output is correct |
2 | Correct | 5 ms | 384 KB | Output is correct |
3 | Correct | 6 ms | 384 KB | Output is correct |
4 | Correct | 6 ms | 384 KB | Output is correct |
5 | Correct | 5 ms | 384 KB | Output is correct |
6 | Correct | 5 ms | 384 KB | Output is correct |
7 | Correct | 5 ms | 384 KB | Output is correct |
8 | Correct | 6 ms | 384 KB | Output is correct |
9 | Correct | 6 ms | 384 KB | Output is correct |
10 | Correct | 6 ms | 512 KB | Output is correct |
11 | Correct | 6 ms | 512 KB | Output is correct |
12 | Correct | 6 ms | 512 KB | Output is correct |
13 | Correct | 6 ms | 384 KB | Output is correct |
14 | Correct | 5 ms | 384 KB | Output is correct |
15 | Correct | 6 ms | 512 KB | Output is correct |