結果
問題 | No.83 最大マッチング |
ユーザー | ramendaisuki |
提出日時 | 2020-03-20 22:05:07 |
言語 | Python3 (3.12.2 + numpy 1.26.4 + scipy 1.12.0) |
結果 |
RE
|
実行時間 | - |
コード長 | 331 bytes |
コンパイル時間 | 145 ms |
コンパイル使用メモリ | 10,472 KB |
実行使用メモリ | 12,668 KB |
最終ジャッジ日時 | 2023-08-21 16:43:24 |
合計ジャッジ時間 | 7,618 ms |
ジャッジサーバーID (参考情報) |
judge15 / judge12 |
(要ログイン)
テストケース
テストケース表示入力 | 結果 | 実行時間 実行使用メモリ |
---|---|---|
testcase_00 | AC | 16 ms
7,888 KB |
testcase_01 | AC | 17 ms
7,800 KB |
testcase_02 | AC | 16 ms
7,764 KB |
testcase_03 | AC | 16 ms
7,912 KB |
testcase_04 | AC | 15 ms
7,812 KB |
testcase_05 | AC | 15 ms
7,884 KB |
testcase_06 | AC | 16 ms
7,772 KB |
testcase_07 | AC | 16 ms
7,708 KB |
testcase_08 | AC | 15 ms
7,780 KB |
testcase_09 | RE | - |
testcase_10 | TLE | - |
testcase_11 | -- | - |
testcase_12 | -- | - |
ソースコード
n = int(input()) if n % 2 == 0: x = int(n / 2) ans = 0 for i in range(1, x + 1): ans += 10**(x - i) else: ans = 0 if n == 1: pass else: x = int(n // 2) y = int(n % 2) ans = 7 * 10 ** (x-1) for i in range(1, x): ans += 10 ** ((x-1) -i) print(ans)