結果

問題 No.1585 Cubic Number
ユーザー AsahiAsahi
提出日時 2023-02-06 08:29:46
言語 Java21
(openjdk 21)
結果
AC  
実行時間 133 ms / 1,000 ms
コード長 619 bytes
コンパイル時間 1,965 ms
コンパイル使用メモリ 71,396 KB
実行使用メモリ 57,708 KB
最終ジャッジ日時 2023-09-17 20:32:08
合計ジャッジ時間 7,326 ms
ジャッジサーバーID
(参考情報)
judge11 / judge14
このコードへのチャレンジ(β)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 130 ms
55,868 KB
testcase_01 AC 130 ms
55,212 KB
testcase_02 AC 130 ms
55,680 KB
testcase_03 AC 129 ms
55,236 KB
testcase_04 AC 129 ms
55,676 KB
testcase_05 AC 129 ms
55,568 KB
testcase_06 AC 129 ms
55,240 KB
testcase_07 AC 129 ms
55,760 KB
testcase_08 AC 130 ms
55,648 KB
testcase_09 AC 131 ms
55,608 KB
testcase_10 AC 129 ms
55,672 KB
testcase_11 AC 130 ms
55,512 KB
testcase_12 AC 132 ms
55,644 KB
testcase_13 AC 131 ms
55,668 KB
testcase_14 AC 133 ms
55,944 KB
testcase_15 AC 130 ms
55,420 KB
testcase_16 AC 128 ms
55,532 KB
testcase_17 AC 128 ms
55,524 KB
testcase_18 AC 130 ms
55,480 KB
testcase_19 AC 131 ms
55,796 KB
testcase_20 AC 130 ms
55,512 KB
testcase_21 AC 131 ms
55,636 KB
testcase_22 AC 128 ms
55,476 KB
testcase_23 AC 129 ms
57,708 KB
testcase_24 AC 129 ms
55,568 KB
testcase_25 AC 128 ms
55,564 KB
testcase_26 AC 129 ms
55,456 KB
testcase_27 AC 129 ms
55,452 KB
testcase_28 AC 128 ms
55,388 KB
testcase_29 AC 128 ms
55,664 KB
testcase_30 AC 129 ms
55,480 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

import java.util.*;
import java.io.*;
import java.math.*;
// import java.util.stream.Stream;

class Main{
    static BufferedReader buff = new BufferedReader(new InputStreamReader(System.in));
    static StringTokenizer st;
    static PrintWriter output = new PrintWriter(System.out);
    static Scanner sc = new Scanner(System.in);
    public static void main(String[] args) throws IOException{
        long n = sc.nextLong();
        boolean ok = false;
        for(long i=1;i<=1000000;i++) {
            if( i * i * i  == n ) ok = true;
        }
        output.print(ok?"Yes":"No");
        output.flush();
    }
}
0