結果

問題 No.1910 High Element on Grid
ユーザー googol_S0googol_S0
提出日時 2022-04-22 21:27:31
言語 PyPy3
(7.3.15)
結果
AC  
実行時間 132 ms / 2,000 ms
コード長 513 bytes
コンパイル時間 991 ms
コンパイル使用メモリ 87,080 KB
実行使用メモリ 79,564 KB
最終ジャッジ日時 2023-09-06 07:46:04
合計ジャッジ時間 12,527 ms
ジャッジサーバーID
(参考情報)
judge15 / judge12
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 69 ms
71,192 KB
testcase_01 AC 69 ms
71,468 KB
testcase_02 AC 71 ms
71,244 KB
testcase_03 AC 69 ms
71,376 KB
testcase_04 AC 69 ms
71,212 KB
testcase_05 AC 70 ms
71,204 KB
testcase_06 AC 70 ms
71,168 KB
testcase_07 AC 68 ms
70,988 KB
testcase_08 AC 71 ms
71,012 KB
testcase_09 AC 70 ms
71,240 KB
testcase_10 AC 68 ms
71,208 KB
testcase_11 AC 132 ms
78,868 KB
testcase_12 AC 115 ms
78,880 KB
testcase_13 AC 116 ms
78,860 KB
testcase_14 AC 123 ms
79,212 KB
testcase_15 AC 110 ms
78,580 KB
testcase_16 AC 110 ms
78,500 KB
testcase_17 AC 111 ms
78,568 KB
testcase_18 AC 117 ms
78,892 KB
testcase_19 AC 111 ms
78,508 KB
testcase_20 AC 113 ms
78,500 KB
testcase_21 AC 113 ms
78,880 KB
testcase_22 AC 106 ms
78,268 KB
testcase_23 AC 118 ms
78,828 KB
testcase_24 AC 106 ms
78,468 KB
testcase_25 AC 114 ms
78,724 KB
testcase_26 AC 113 ms
78,752 KB
testcase_27 AC 112 ms
78,924 KB
testcase_28 AC 102 ms
78,148 KB
testcase_29 AC 106 ms
78,356 KB
testcase_30 AC 110 ms
78,552 KB
testcase_31 AC 69 ms
71,380 KB
testcase_32 AC 126 ms
79,564 KB
testcase_33 AC 126 ms
79,492 KB
testcase_34 AC 126 ms
79,480 KB
testcase_35 AC 123 ms
79,396 KB
testcase_36 AC 80 ms
76,412 KB
testcase_37 AC 104 ms
78,296 KB
testcase_38 AC 95 ms
77,864 KB
testcase_39 AC 92 ms
77,660 KB
testcase_40 AC 82 ms
76,644 KB
testcase_41 AC 97 ms
78,120 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

H,W=map(int,input().split())
R=list(map(int,input().split()))
C=list(map(int,input().split()))
ANS=[list(range(i*3000+3,i*3000+3+W*2,2)) for i in range(H)]
for i in range(H):
  for j in range(W):
    if i==0 and j==0:
      ANS[i][j]=10**9
    elif i==0 or j==0:
      ANS[i][j]=(10**6*j)+i*3+10
for i in range(1,W):
  for j in range(C[i]-1):
    ANS[j+1][i]=ANS[j][i]+100
  for j in range(C[i]-1,H-1):
    ANS[j+1][i]=ANS[j][i]-1
for i in range(1,H):
  ANS[i][0]=ANS[i][-R[i]]
for i in range(H):
  print(*ANS[i])
0