RosettaCodeData/Task/Babbage-problem/C++/babbage-problem.cpp

10 lines
234 B
C++

#include <iostream>
int main( ) {
int current = 0 ;
while ( ( current * current ) % 1000000 != 269696 )
current++ ;
std::cout << "The square of " << current << " is " << (current * current) << " !\n" ;
return 0 ;
}