結果
問題 | No.1585 Cubic Number |
ユーザー |
|
提出日時 | 2021-07-08 23:26:58 |
言語 | C++14 (gcc 13.3.0 + boost 1.87.0) |
結果 |
TLE
|
実行時間 | - |
コード長 | 310 bytes |
コンパイル時間 | 1,552 ms |
コンパイル使用メモリ | 165,724 KB |
実行使用メモリ | 16,952 KB |
最終ジャッジ日時 | 2024-07-01 13:15:53 |
合計ジャッジ時間 | 5,905 ms |
ジャッジサーバーID (参考情報) |
judge2 / judge1 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
sample | -- * 3 |
other | TLE * 1 -- * 27 |
ソースコード
#include <bits/stdc++.h> using namespace std; long long n; int main(){ cin >> n; double x = cbrt(n); bool ans = false; for(int i = 1; i*i*i <= n; i++){ if(i*i*i == n) ans = true; else ans = false; } if(ans) cout << "Yes" << endl; else cout << "No" << endl; }