练习:

第一章

6. 编写算法,求一元多项式的值

   1 double p(double x, double a[], int n) {
   2    double result = 0.0;
   3    int i = 0;
   4    for(i = n; i >= 0; i--) {
   5       result *= x;
   6       result += a[i];
   7    }
   8 }
ch3n2k.com | Copyright (c) 2004-2020 czk.