結果

問題 No.1585 Cubic Number
ユーザー bluemeganebluemegane
提出日時 2021-07-08 22:32:00
言語 C#(mono)
(mono 6.12.0.158)
結果
AC  
実行時間 53 ms / 1,000 ms
コード長 359 bytes
コンパイル時間 1,357 ms
使用メモリ 16,788 KB
最終ジャッジ日時 2023-02-01 20:02:43
合計ジャッジ時間 4,495 ms
ジャッジサーバーID
(参考情報)
judge13 / judge14
このコードへのチャレンジ(β)

テストケース

テストケース表示
入力 結果 実行時間
使用メモリ
testcase_00 AC 52 ms
14,844 KB
testcase_01 AC 51 ms
14,676 KB
testcase_02 AC 52 ms
14,784 KB
testcase_03 AC 50 ms
14,776 KB
testcase_04 AC 50 ms
14,640 KB
testcase_05 AC 51 ms
14,708 KB
testcase_06 AC 51 ms
14,700 KB
testcase_07 AC 50 ms
14,808 KB
testcase_08 AC 52 ms
14,712 KB
testcase_09 AC 51 ms
14,752 KB
testcase_10 AC 51 ms
14,644 KB
testcase_11 AC 50 ms
14,648 KB
testcase_12 AC 51 ms
14,608 KB
testcase_13 AC 51 ms
14,636 KB
testcase_14 AC 51 ms
14,868 KB
testcase_15 AC 50 ms
14,768 KB
testcase_16 AC 50 ms
14,712 KB
testcase_17 AC 52 ms
16,788 KB
testcase_18 AC 53 ms
14,604 KB
testcase_19 AC 53 ms
14,740 KB
testcase_20 AC 51 ms
14,716 KB
testcase_21 AC 51 ms
14,696 KB
testcase_22 AC 51 ms
14,768 KB
testcase_23 AC 52 ms
14,644 KB
testcase_24 AC 52 ms
14,712 KB
testcase_25 AC 53 ms
14,716 KB
testcase_26 AC 52 ms
14,696 KB
testcase_27 AC 51 ms
14,820 KB
testcase_28 AC 50 ms
14,720 KB
testcase_29 AC 50 ms
14,704 KB
testcase_30 AC 51 ms
14,708 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

using System;

public class Hello
{
    static void Main()
    {
        var n = long.Parse(Console.ReadLine().Trim());
        getAns(n);
    }
    static void getAns(long n)
    {
        for (long i = 1; i * i * i <= n; i++)
        {
            if (i * i * i == n) { Console.WriteLine("Yes"); return; }
        }
        Console.WriteLine("No");
    }
}
0