-
More help please
#include <iostream.h>
#include <stdlib.h>
#include <string.h>
#include <conio.h>
int main()
{
int pi;
{
cout << 1/2.545584412*8;
system("pause");
}
return 0;
}
That is my new code. Now, it shows only 3.1427, how do I get it do display more digits? Also, when beside the equation, I take away the ;, and << /n;, the program does not run, and when it is <<"/n";, It does not work.
-
Sorry, this was supposed to be a reply. I will repost it as a reply in the "My PI Program" thread.
Moderator, please delete this.
-
what are you trying to do with this program? You have pi declared, but are doing nothing with it. Plus you got another set of braces inside the main function.
-
I have pi declared because I forgot to get rid of it while trying to rid it of a bug. I want the program to display infinite digits it PI.