結果
問題 |
No.51 やる気の問題
|
ユーザー |
![]() |
提出日時 | 2016-02-18 10:00:51 |
言語 | D (dmd 2.109.1) |
結果 |
RE
|
実行時間 | - |
コード長 | 312 bytes |
コンパイル時間 | 697 ms |
コンパイル使用メモリ | 99,432 KB |
実行使用メモリ | 6,948 KB |
最終ジャッジ日時 | 2024-06-12 02:53:32 |
合計ジャッジ時間 | 1,887 ms |
ジャッジサーバーID (参考情報) |
judge1 / judge4 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
sample | AC * 3 |
other | AC * 14 RE * 6 |
ソースコード
import std.stdio, std.conv, std.string, std.range, std.math, std.algorithm; void main() { auto W = readln.strip.to!int; auto D = readln.strip.to!int; int work = W; foreach_reverse (d; 2 .. D + 1) { work -= work / d ^^ 2; } work.writeln; }