結果
問題 |
No.648 お や す み
|
ユーザー |
|
提出日時 | 2018-02-10 14:03:03 |
言語 | C++14 (gcc 13.3.0 + boost 1.87.0) |
結果 |
WA
|
実行時間 | - |
コード長 | 334 bytes |
コンパイル時間 | 524 ms |
コンパイル使用メモリ | 68,292 KB |
実行使用メモリ | 6,824 KB |
最終ジャッジ日時 | 2024-10-13 09:42:07 |
合計ジャッジ時間 | 2,652 ms |
ジャッジサーバーID (参考情報) |
judge4 / judge3 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
other | WA * 84 |
ソースコード
#include <iostream> #include <stdio.h> #include <stdlib.h> #include <math.h> using namespace std; int main(void) { long double t; long double n; cin >> n; t = (sqrtl(1+8*n)-1)/2; int a = t; if((t - a) == 0) cout << "Yes" <<endl << t <<endl; else cout << "No" << endl; return 0; }