結果
問題 |
No.839 Keep Distance and Nobody Explodes
|
ユーザー |
![]() |
提出日時 | 2020-03-13 23:13:29 |
言語 | Python3 (3.13.1 + numpy 2.2.1 + scipy 1.14.1) |
結果 |
WA
|
実行時間 | - |
コード長 | 546 bytes |
コンパイル時間 | 273 ms |
コンパイル使用メモリ | 12,672 KB |
実行使用メモリ | 48,060 KB |
最終ジャッジ日時 | 2024-11-22 23:38:44 |
合計ジャッジ時間 | 19,239 ms |
ジャッジサーバーID (参考情報) |
judge4 / judge2 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
other | AC * 1 WA * 29 |
ソースコード
#!/usr/bin/env python3.8 # %% import sys read = sys.stdin.buffer.read readline = sys.stdin.buffer.readline readlines = sys.stdin.buffer.readlines # %% import numpy as np # %% N = int(read()) # %% M = N // 2 A = np.empty((N, N), np.int32) A[:M, :M] = np.arange(1, N * N // 2, 2).reshape(M, M) A[M:, M:] = np.arange(2, N * N // 2 + 1, 2).reshape(M, M) A[:M, M:] = np.arange(N * N // 2 + 1, N * N, 2).reshape(M, M) A[M:, :M] = np.arange(N * N // 2 + 2, N * N + 1, 2).reshape(M, M) # %% print('\n'.join(' '.join(row) for row in A.astype(str)))