Laitofai

dasdasdsadfas

Dec 16th, 2017
139
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C++ 0.35 KB | None | 0 0
  1. #include <iostream>
  2. #include <cmath>
  3.  
  4. using namespace std;
  5.  
  6. int main()
  7. {
  8.     setlocale(LC_ALL,"Russian");
  9.     double t, m, k=0;
  10.     cout<<"Введите m больше чем 1:"<<endl;
  11.     cin>>m;
  12.     while(1){
  13.         t=pow(4,k);
  14.         if(t>=m){k--;break;}
  15.         k++;
  16.         }cout<<"Число k равно "<<k<<endl;
  17.     return 0;
  18. }
Advertisement
Add Comment
Please, Sign In to add comment