Skip to content

Commit b62662c

Browse files
committed
Bear and Big Brother
1 parent fd76428 commit b62662c

File tree

1 file changed

+16
-0
lines changed

1 file changed

+16
-0
lines changed

791A.cpp

+16
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
#include<iostream>
2+
using namespace std;
3+
4+
int main(){
5+
int a, b;
6+
cin>>a;
7+
cin>>b;
8+
int year = 0;
9+
10+
while(b >= a){
11+
a *= 3;
12+
b *= 2;
13+
year++;
14+
}
15+
cout<<year;
16+
}

0 commit comments

Comments
 (0)