結果
| 問題 | 
                            No.565 回転拡大
                             | 
                    
| コンテスト | |
| ユーザー | 
                             teketeke5000
                         | 
                    
| 提出日時 | 2017-09-10 20:03:58 | 
| 言語 | C++11(廃止可能性あり)  (gcc 13.3.0)  | 
                    
| 結果 | 
                             
                                WA
                                 
                             
                            
                         | 
                    
| 実行時間 | - | 
| コード長 | 1,443 bytes | 
| コンパイル時間 | 1,277 ms | 
| コンパイル使用メモリ | 159,428 KB | 
| 実行使用メモリ | 5,248 KB | 
| 最終ジャッジ日時 | 2024-11-07 12:50:17 | 
| 合計ジャッジ時間 | 2,267 ms | 
| 
                            ジャッジサーバーID (参考情報)  | 
                        judge4 / judge3 | 
(要ログイン)
| ファイルパターン | 結果 | 
|---|---|
| sample | AC * 3 | 
| other | AC * 15 WA * 15 | 
ソースコード
#include <bits/stdc++.h>
using namespace std;
typedef long long ll;
int main(void) {
    int R,K,H,W;
    char tmp;
    cin >> R >> K >> H >> W;
    bool c[H][W];
    for (int i=0; i<H; i++) for (int j=0; j<W; j++) {
        cin >> tmp;
        if (tmp == '#') c[i][j] = true;
        else c[i][j] = false;
    }
    switch(R/90) {
        case 0:
            for (int i=0; i<H*K; i++) {
                for (int j=0; j<W*K; j++) {
                    if (c[i/K][j/K]) cout << '#';
                    else cout << '.';
                }
                cout << endl;
            }
            break;
        case 1:
            for (int j=0; j<W*K; j++) {
                for (int i=0; i<H*K; i++) {
                    if (c[i/K][j/K]) cout << '#';
                    else cout << '.';
                }
                cout << endl;
            }
            break;
        case 2:
            for (int i=H*K-1; i>=0; i--) {
                for (int j=W*K-1; j>=0; j--) {
                    if (c[i/K][j/K]) cout << '#';
                    else cout << '.';
                }
                cout << endl;
            }
            break;
        case 3:
            for (int j=W*K-1; j>=0; j--) {
                for (int i=H*K-1; i>=0; i--) {
                    if (c[i/K][j/K]) cout << '#';
                    else cout << '.';
                }
                cout << endl;
            }
            break;
    }
    return 0;
}
            
            
            
        
            
teketeke5000