#include <iostream>using namespace std; int main() {int s = 900, n = 30;while (s < n) {s = s*s - 20;n = n + 30;}if (s > n) {n++;}cout << n;return 0;;}
Standard input is empty
31
The brand new service which powers Ideone!
Widget for compiling and running the source code in a web browser!