"Helo world"(like my first program in C++ same in java)... My name is Zoran, from Macedonia. Hi to all...:seeya: Поздрав на сите...:seeya: Привет всем...:seeya: Hallo an alle...:seeya: Salut à tous...:seeya: Ciao a tutti...:seeya:
Hi to all... English Поздрав на сите... Macedonian my natural.. Привет всем... Russian Hallo an alle... German Salut à tous... French Ciao a tutti... Italian
Code: #include <iostream> using namespace std; void main() { long int n; n=0; float x,y; do { n++; x=1+1/(float)n; y=1-1/(float)n; }while (x!=y); cout<<n<<" "<<x<<" "<<y; } This is the code with mistake in arithmetic precision. What's wrong with the code? And if i put the "cout" line before while, program doesn't stop.Why? When x & y will be same,or do they ever will be same? Can any1 answer my questions? Thanks in advance.