Thanks for the correction it was a little fuzzy in my mind. I found that one on google a while back ago and made a c program out of it. but i lost the source code.
Code:
unsigned double float pi;
unsigned int top;
unsigned int bottem;
unsigned int count;
int main()
{
top = 2;
bottem = 1;
pi = top/bottem;
while(count < 10000)
{
pi *= top/bottem;
bottem += 2;
pi *= top/bottem;
top += 2;
count++
}
printf ("pi = %f", pi*2);
}