Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include <stdio.h>
- #include <math.h>
- int main()
- {
- float n = 1;
- float sum;
- do
- {
- sum = 1 / (n * (n + 1));
- printf("%f", sum);
- n ++;
- }
- while (sum>0.0001);
- return 0;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement