|
|
back to board1001. Обратный корень Posted by Shaft 5 Apr 2015 02:00 #include <iostream> #include <cmath> #include <stack> using namespace std; int main() { stack <unsigned long long> __stack_sqrt; unsigned long long ent_val; while(cin >> skipws >> ent_val) __stack_sqrt.push(ent_val); cout.setf(ios::showpoint); cout.precision(5); while(!(__stack_sqrt.empty())) { cout << sqrt(__stack_sqrt.top()) << endl; __stack_sqrt.pop(); } return 0; } Compilator wrote "wrong answer", but when i've test it, everything is ok! Please help smb, what's th problem? |
|
|