結果
問題 |
No.2958 Placing Many L-s
|
ユーザー |
|
提出日時 | 2024-10-23 21:58:18 |
言語 | Python3 (3.13.1 + numpy 2.2.1 + scipy 1.14.1) |
結果 |
WA
|
実行時間 | - |
コード長 | 528 bytes |
コンパイル時間 | 233 ms |
コンパイル使用メモリ | 12,416 KB |
実行使用メモリ | 10,752 KB |
最終ジャッジ日時 | 2024-11-08 20:50:49 |
合計ジャッジ時間 | 7,040 ms |
ジャッジサーバーID (参考情報) |
judge1 / judge2 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
sample | WA * 2 |
other | WA * 29 |
ソースコード
import re import sys content = input() pattern = r'^(\d+)$' result = re.match(pattern, content) if not result: sys.exit("format error.") T = int(content) if not (1 <= T and T <= 500): sys.exit("T") for t in range(T): content = input() pattern = r'^(\d+) (\d+)$' result = re.match(pattern, content) if not result: sys.exit("format error.") N, M = map(int, content.split()) if not (1 <= N and N <= 500): sys.exit("N") if not (1 <= M and M <= 500): sys.exit("M")