結果
問題 | No.219 巨大数の概算 |
ユーザー | mai |
提出日時 | 2018-12-22 13:06:03 |
言語 | Ruby (3.4.1) |
結果 |
AC
|
実行時間 | 116 ms / 1,500 ms |
コード長 | 221 bytes |
コンパイル時間 | 59 ms |
コンパイル使用メモリ | 7,552 KB |
実行使用メモリ | 12,800 KB |
最終ジャッジ日時 | 2024-09-25 10:09:42 |
合計ジャッジ時間 | 8,086 ms |
ジャッジサーバーID (参考情報) |
judge1 / judge5 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
sample | AC * 1 |
other | AC * 51 |
コンパイルメッセージ
Syntax OK
ソースコード
gets.to_i.times do a,b = gets.split.map(&:to_i) u = Math.log(a, 10)*b t = 10**(u-u.floor) #q = b.to_f/Math.log(10, a)-1e-5 #p u, q puts "#{t.to_i} #{((t-t.to_i)*10).to_i} #{u.to_i}" end