Advertisement
ilyaDubovtsev

Untitled

Jun 13th, 2018
76
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C++ 0.20 KB | None | 0 0
  1. #include "stdafx.h"
  2. #include <iostream>
  3.  
  4. using namespace std;
  5.  
  6. int main()
  7. {
  8.     double a, b = 2;
  9.     cout << "Vvedite a" << endl;
  10.     cin >> a;
  11.     while (a < 1 + 1 / b)
  12.         b += 1;
  13.     cout << 1 + 1 / b;
  14. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement