kiem tien, kiem tien online, kiem tien truc tuyen, kiem tien tren mang
Sunday, December 28, 2014

viết chương trình c tính số e và lũy thừa cơ số e

//tính số e, lũy thừa với số e
#include<stdio.h>
#include<conio.h>
#include<math.h>
double e(double x)
{
double tong = 1, i = 1, ps = 1;
while (ps > 0.00001)
{
ps = ps*x / i;
tong += ps;
i++;
}
return tong;
}
void main()
{
printf("e^1=%lf\ne^7=%lf\n", e(1),e(7));
}
28 Dec 2014

0 comments:

Post a Comment

:) :)) ;(( :-) =)) ;( ;-( :d :-d @-) :p :o :>) (o) [-( :-? (p) :-s (m) 8-) :-t :-b b-( :-# =p~ $-) (b) (f) x-) (k) (h) (c) cheer
Click to see the code!
To insert emoticon you must added at least one space before the code.

domain, domain name, premium domain name for sales

Popular Posts