結果
| 問題 | No.1042 愚直大学 |
| コンテスト | |
| ユーザー |
umezo
|
| 提出日時 | 2020-05-01 21:33:16 |
| 言語 | C++17 (gcc 15.2.0 + boost 1.89.0) |
| 結果 |
TLE
|
| 実行時間 | - |
| コード長 | 598 bytes |
| 記録 | |
| コンパイル時間 | 1,379 ms |
| コンパイル使用メモリ | 249,252 KB |
| 実行使用メモリ | 10,112 KB |
| 最終ジャッジ日時 | 2026-06-09 21:15:12 |
| 合計ジャッジ時間 | 5,442 ms |
|
ジャッジサーバーID (参考情報) |
judge1_0 / judge1_1 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| sample | AC * 2 |
| other | AC * 2 TLE * 1 -- * 20 |
ソースコード
#define _GLIBCXX_DEBUG
#define rep(i, n) for (int i = 0; i < (int)(n); i++)
#define ALL(v) v.begin(), v.end()
typedef long long ll;
template<class T>bool chmax(T &a, const T &b) { if (a<b) { a=b; return 1; } return 0; }
template<class T>bool chmin(T &a, const T &b) { if (b<a) { a=b; return 1; } return 0; }
#include <bits/stdc++.h>
using namespace std;
int main() {
double p,q;
cin>>p>>q;
double n=1.0;
while(n*n<=p+q*n*log2(n)){
n++;
}
n--;
while(n*n<=p+q*n*log2(n)){
n+=0.000001;
}
n-=0.000001;
cout << fixed << setprecision(15) << n <<endl;
return 0;
}
umezo