mirror of
https://github.com/wczffl-503/OI-Codes.git
synced 2025-07-08 02:13:51 +08:00
更新了许多
This commit is contained in:
10
计算多项式的值.cpp
Normal file
10
计算多项式的值.cpp
Normal file
@ -0,0 +1,10 @@
|
||||
#include <iostream>
|
||||
#include <iomanip>
|
||||
#include <cmath>
|
||||
using namespace std;
|
||||
int main(){
|
||||
double a,b,c,d,x;
|
||||
cin >>x>>a>>b>>c>>d;
|
||||
cout <<fixed<<setprecision(7)<<a*pow(x,3)+b*pow(x,2)+c*x+d;
|
||||
return 0;
|
||||
}
|
Reference in New Issue
Block a user