Calculating Pi C++ Program

Embed Size (px)

DESCRIPTION

Program which calculates pi to the required precision in C++

Citation preview

  • #include #include #include

    using namespace std;

    void input(string& x, int& y, int& z);

    int main(){ int denom = 3; int terms=0; int steps=0;

    double newPi = 4.0;

    bool condition = true;

    string prompt= "Enter the number of terms to use: ";

    input( prompt, terms, steps );

    cout

  • cout