SHARE
TWEET

Untitled

a guest May 19th, 2019 72 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. #include <iostream>
  2.  
  3. using namespace std;
  4.  
  5. int main()
  6. {
  7.     int x = 0;
  8.     int y = 0;
  9.     int i = 1;
  10.     float sum = 0.0;
  11.     cin >> x >> y;
  12.     while (sum <= y)
  13.     {
  14.         if (i == 1)
  15.             sum = x;
  16.         else
  17.             sum += sum*1.7;
  18.         i++;
  19.     }
  20.     cout << i;
  21.     return 0;
  22. }
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
 
Top