結果
| 問題 | No.784 「,(カンマ)」 |
| コンテスト | |
| ユーザー |
pasoconhoshii
|
| 提出日時 | 2019-02-08 23:58:24 |
| 言語 | Python3 (3.13.1 + numpy 2.2.1 + scipy 1.14.1) |
| 結果 |
AC
|
| 実行時間 | 32 ms / 2,000 ms |
| コード長 | 348 bytes |
| 記録 | |
| コンパイル時間 | 93 ms |
| コンパイル使用メモリ | 12,416 KB |
| 実行使用メモリ | 10,752 KB |
| 最終ジャッジ日時 | 2024-07-01 11:47:14 |
| 合計ジャッジ時間 | 1,029 ms |
|
ジャッジサーバーID (参考情報) |
judge2 / judge5 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| sample | AC * 3 |
| other | AC * 10 |
ソースコード
#!/mnt/c/Users/moiki/bash/env/bin/python
# N,M = map(int, input().split())
N = int(input())
strN = reversed(str(N))
ans = []
if len(str(N)) <= 3:
print(str(N))
exit(0)
for e,i in enumerate(strN):
ans.append(i)
if e % 3 == 2:
ans.append(",")
if ans[-1] == ",":
ans = ans[:-1]
print("".join(ans[::-1]))
pasoconhoshii