题解 | #牛牛的Hermite多项式#
牛牛的Hermite多项式
http://www.nowcoder.com/practice/0c58f8e5673a406cb0e2f5ccf2c671d4
#include <stdio.h>
int Hermite(int n,int x)
{
if(n <= 0)
{
return 1;
}
else if(1 == n)
{
return 2x;
}
else
{
return 2xHermite(n-1,x)-2(n-1)*Hermite(n-2,x);
}
}
int main() { int pn = 0; int px = 0; scanf("%d%d",&pn,&px); printf("%d",Hermite(pn,px)); retur