結果
問題 | No.2728 Grid Expansion |
ユーザー |
|
提出日時 | 2024-05-11 18:03:00 |
言語 | C++17 (gcc 13.3.0 + boost 1.87.0) |
結果 |
AC
|
実行時間 | 2 ms / 2,000 ms |
コード長 | 833 bytes |
コンパイル時間 | 1,984 ms |
コンパイル使用メモリ | 199,624 KB |
最終ジャッジ日時 | 2025-02-21 13:42:28 |
ジャッジサーバーID (参考情報) |
judge4 / judge1 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
sample | AC * 3 |
other | AC * 15 |
ソースコード
#include <bits/stdc++.h>using namespace std;using ll = long long;using ull = unsigned long long;using Matrix = vector<vector<ll>>;const int inf = 1000000000;const ll INF = 1000000000000000000;const ll mod = 998244353;const ull mod_hash = (1UL << 61) - 1;const vector<int> dx = {0, 1, 0, -1, 1, 1, -1, -1};const vector<int> dy = {1, 0, -1, 0, 1, -1, 1, -1};int main(){int N, K;cin>>N>>K;vector<vector<char>> G(N, vector<char>(N));for (int i = 0; i < N; i++) {for (int j = 0; j < N; j++) {cin>>G[i][j];}}vector<vector<char>> A(N*K, vector<char>(N*K));for (int i = 0; i < N*K; i++) {for (int j = 0; j < N*K; j++) {A[i][j] = G[i/K][j/K];}}for (int i = 0; i < N*K; i++) {for (int j = 0; j < N*K; j++) {cout<<A[i][j];}cout<<endl;}return 0;}