結果
| 問題 |
No.338 アンケート機能
|
| コンテスト | |
| ユーザー |
t8m8⛄️
|
| 提出日時 | 2016-04-17 15:32:42 |
| 言語 | Nim (2.2.0) |
| 結果 |
AC
|
| 実行時間 | 2 ms / 2,000 ms |
| コード長 | 347 bytes |
| コンパイル時間 | 2,858 ms |
| コンパイル使用メモリ | 65,952 KB |
| 実行使用メモリ | 5,376 KB |
| 最終ジャッジ日時 | 2024-06-29 13:35:40 |
| 合計ジャッジ時間 | 3,713 ms |
|
ジャッジサーバーID (参考情報) |
judge5 / judge2 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| sample | AC * 3 |
| other | AC * 28 |
ソースコード
import strutils, sequtils
proc round(x: float): int {.importc: "round", header: "<math.h>".}
var
a = stdin.readLine.split.map(parseInt)
ans = 1000
for i in 0..200:
for j in 0..200:
if i + j == 0: continue
if a[0] == round((100*i) / (i+j)) and a[1] == round((100*j) / (i+j)):
ans = ans.min(i+j)
ans.echo
t8m8⛄️