| Run ID | 作者 | 问题 | 语言 | 测评结果 | 时间 | 内存 | 代码长度 | 提交时间 |
|---|---|---|---|---|---|---|---|---|
| 84038 | sh25_shenpy | 求指数方程的根(fxroot) [2*+] ** | C++ | 运行超时 | 1000 MS | 248 KB | 449 | 2026-02-06 19:31:29 |
#include <bits/stdc++.h> using namespace std; inline double f(double x){return pow(2,x)+pow(3,x)-pow(4,x);} const double x0=1e-10; int main( ) { for(double x=1;x<=2;x+=x0){ if(f(x)*f(x+x0)<0){ cout<<x; return 0; } else if(f(x)==0){ cout<<x; return 0; } else if(f(x+x0)==0){ cout<<x+x0; return 0; } } }