結果

問題 No.1585 Cubic Number
ユーザー bluemeganebluemegane
提出日時 2021-07-08 22:32:00
言語 C#(csc)
(csc 3.9.0)
結果
AC  
実行時間 55 ms / 1,000 ms
コード長 359 bytes
コンパイル時間 1,960 ms
コンパイル使用メモリ 60,776 KB
実行使用メモリ 22,796 KB
最終ジャッジ日時 2023-09-14 06:07:44
合計ジャッジ時間 3,678 ms
ジャッジサーバーID
(参考情報)
judge14 / judge13
このコードへのチャレンジ(β)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 55 ms
20,724 KB
testcase_01 AC 53 ms
20,712 KB
testcase_02 AC 53 ms
18,648 KB
testcase_03 AC 53 ms
20,672 KB
testcase_04 AC 52 ms
20,648 KB
testcase_05 AC 52 ms
18,604 KB
testcase_06 AC 52 ms
20,748 KB
testcase_07 AC 54 ms
20,684 KB
testcase_08 AC 52 ms
20,628 KB
testcase_09 AC 53 ms
22,736 KB
testcase_10 AC 53 ms
20,700 KB
testcase_11 AC 51 ms
20,632 KB
testcase_12 AC 52 ms
20,692 KB
testcase_13 AC 52 ms
22,704 KB
testcase_14 AC 52 ms
22,784 KB
testcase_15 AC 51 ms
22,684 KB
testcase_16 AC 50 ms
20,548 KB
testcase_17 AC 51 ms
22,740 KB
testcase_18 AC 53 ms
20,572 KB
testcase_19 AC 52 ms
20,748 KB
testcase_20 AC 52 ms
20,628 KB
testcase_21 AC 53 ms
20,692 KB
testcase_22 AC 52 ms
20,744 KB
testcase_23 AC 53 ms
22,784 KB
testcase_24 AC 53 ms
20,672 KB
testcase_25 AC 51 ms
20,736 KB
testcase_26 AC 51 ms
22,724 KB
testcase_27 AC 50 ms
22,796 KB
testcase_28 AC 50 ms
22,692 KB
testcase_29 AC 50 ms
20,812 KB
testcase_30 AC 52 ms
20,648 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