Submission #6420200
Source Code Expand
#define _CRT_SECURE_NO_WARNINGS #include<bits/stdc++.h> using namespace std; #ifndef FAST_IO #define IOS ios_base::sync_with_stdio(false);cin.tie(nullptr); #endif #define FILE_IO freopen("input.txt","r",stdin) #define int long long #define f first #define s second #define endl '\n' #define all(c) c.begin(),c.end() #define bp __builtin_popcount #define debug(x) cerr << #x << " = " << x << endl; const int MOD = 1e9 + 7; const int INF = 1e18; mt19937 rng(chrono::steady_clock::now().time_since_epoch().count()); template <typename T>void print(T t){for(auto &it : t)cout<<it<<" ";} inline int powerexp(int a, int b, int m = MOD){ int res = 1;while(b){if(b&1)res = res * a % m;a = a * a % m,b >>= 1;}return res % m;} inline int modinv(int a){ return powerexp(a,MOD-2,MOD);} inline int lcm(int a, int b){ int g = __gcd(a,b);return a/g*b;} inline int add(int x, int y){ x += y; if (x >= MOD) x -= MOD; return x;} inline int mul(int x, int y){ return (x * 1ll * y) % MOD;} inline int sub(int x, int y){ x -= y; if (x<0) x += MOD; return x ;} //-------------------< start here >-------------------------// void print_vector(vector<int> v){ for(int i = 0; i < (int)v.size(); i++){ if (i == (int)v.size() - 1) cout << v[i]; else cout << v[i] << " "; } cout << endl; } char grid[100][100]; void solve(){ int h, w; cin >> h >> w; for(int i = 0; i < h + 2; i++){ for(int j = 0; j < w + 2; j++){ grid[i][j] = '#'; } } for(int i = 1; i < h + 1; i++){ for(int j = 1; j < w + 1; j++){ cin >> grid[i][j]; } } for(int i = 0; i < h + 2; i++){ for(int j = 0; j < w + 2; j++){ cout << grid[i][j]; } cout << endl; } } //----------------------------- //comment from here for TOPCODER int32_t main(){ IOS; solve(); //find(); #ifdef LOCAL_DEFINE cerr << "time elapsed " << (double)clock()/CLOCKS_PER_SEC << endl; #endif }
Submission Info
Submission Time | |
---|---|
Task | B - Picture Frame |
User | king_of_sun |
Language | C++14 (GCC 5.4.1) |
Score | 0 |
Code Size | 1961 Byte |
Status | WA |
Exec Time | 2 ms |
Memory | 256 KB |
Judge Result
Set Name | Sample | All | ||||||
---|---|---|---|---|---|---|---|---|
Score / Max Score | 0 / 0 | 0 / 200 | ||||||
Status |
|
|
Set Name | Test Cases |
---|---|
Sample | 0_00.txt, 0_01.txt |
All | 0_00.txt, 0_01.txt, 1_00.txt, 1_01.txt, 1_02.txt, 1_03.txt, 1_04.txt, 1_05.txt, 1_06.txt, 1_07.txt |
Case Name | Status | Exec Time | Memory |
---|---|---|---|
0_00.txt | AC | 1 ms | 256 KB |
0_01.txt | AC | 1 ms | 256 KB |
1_00.txt | AC | 1 ms | 256 KB |
1_01.txt | WA | 1 ms | 256 KB |
1_02.txt | AC | 1 ms | 256 KB |
1_03.txt | WA | 2 ms | 256 KB |
1_04.txt | AC | 1 ms | 256 KB |
1_05.txt | AC | 1 ms | 256 KB |
1_06.txt | AC | 1 ms | 256 KB |
1_07.txt | AC | 1 ms | 256 KB |