結果
| 問題 |
No.2624 Prediction by Average
|
| コンテスト | |
| ユーザー |
titia
|
| 提出日時 | 2024-02-09 23:14:05 |
| 言語 | PyPy3 (7.3.15) |
| 結果 |
WA
|
| 実行時間 | - |
| コード長 | 381 bytes |
| コンパイル時間 | 312 ms |
| コンパイル使用メモリ | 82,320 KB |
| 実行使用メモリ | 70,988 KB |
| 最終ジャッジ日時 | 2024-09-28 16:26:10 |
| 合計ジャッジ時間 | 1,202 ms |
|
ジャッジサーバーID (参考情報) |
judge1 / judge3 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| sample | AC * 1 |
| other | AC * 1 WA * 4 |
ソースコード
import sys
input = sys.stdin.readline
T=int(input())
for tests in range(T):
N,S=input().split()
N=int(N)
x=S.index(".")
S=int(S[x+1:])
ANS=0
for i in range(1,min(N,15000)+1):
if (S*i)%1000==0:
ANS+=1
else:
if (S*i)//1000!=(S+1)*i//1000:
ANS+=1
if N>15000:
ANS+=N-15000
print(ANS)
titia