結果
問題 | No.32 貯金箱の憂鬱 |
ユーザー |
![]() |
提出日時 | 2017-05-22 14:45:15 |
言語 | Ruby (3.4.1) |
結果 |
AC
|
実行時間 | 93 ms / 5,000 ms |
コード長 | 280 bytes |
コンパイル時間 | 176 ms |
コンパイル使用メモリ | 7,552 KB |
実行使用メモリ | 12,288 KB |
最終ジャッジ日時 | 2024-07-23 04:37:39 |
合計ジャッジ時間 | 1,741 ms |
ジャッジサーバーID (参考情報) |
judge1 / judge3 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
other | AC * 12 |
コンパイルメッセージ
Main.rb:7: warning: assigned but unused variable - s4 Syntax OK
ソースコード
L=gets.to_iM=gets.to_iN=gets.to_idef ryougae(x,y,z)total = x + y * 25 + z * 100s4 = (total / 1000).to_is3 = ((total % 1000) / 100).to_is2 = (((total % 1000) % 100) / 25).to_is1 = (((total % 1000) % 100) % 25).to_ireturn s3 + s2 + s1endputs ryougae(N,M,L)