[ create a new paste ] login | about

Link: http://codepad.org/AnHW4lQP    [ raw code | output | fork ]

C++, pasted on Feb 2:
1
2
3
4
5
6
7
8
9
10
11
12
13
14
#include <bits/stdc++.h>
using namespace std;
int main()
{
    int n=0, i=1;
    float S=1;
    while(1/n<=0.000002)
    {
        S=S+1/n;
        n=n+i;
        i++;
     }
     cout <<S;
}


Output:
1
Line 24: error: bits/stdc++.h: No such file or directory


Create a new paste based on this one


Comments: