日韩性视频-久久久蜜桃-www中文字幕-在线中文字幕av-亚洲欧美一区二区三区四区-撸久久-香蕉视频一区-久久无码精品丰满人妻-国产高潮av-激情福利社-日韩av网址大全-国产精品久久999-日本五十路在线-性欧美在线-久久99精品波多结衣一区-男女午夜免费视频-黑人极品ⅴideos精品欧美棵-人人妻人人澡人人爽精品欧美一区-日韩一区在线看-欧美a级在线免费观看

歡迎訪問 生活随笔!

生活随笔

當前位置: 首頁 > 编程资源 > 编程问答 >内容正文

编程问答

Codeforces A. Bear and Big Brother

發布時間:2023/12/20 编程问答 34 豆豆
生活随笔 收集整理的這篇文章主要介紹了 Codeforces A. Bear and Big Brother 小編覺得挺不錯的,現在分享給大家,幫大家做個參考.
。。。不行。這題之后、不做1000分以下的了。很恥辱 A. Bear and Big Brother time limit per test 1 second memory limit per test 256 megabytes input standard input output standard output

Bear Limak wants to become the largest of bears, or at least to become larger than his brother Bob.

Right now, Limak and Bob weigh?a?and?b?respectively. It's guaranteed that Limak's weight is smaller than or equal to his brother's weight.

Limak eats a lot and his weight is tripled after every year, while Bob's weight is doubled after every year.

After how many full years will Limak become strictly larger (strictly heavier) than Bob?

Input

The only line of the input contains two integers?a?and?b?(1?≤?a?≤?b?≤?10)?— the weight of Limak and the weight of Bob respectively.

Output

Print one integer, denoting the integer number of years after which Limak will become strictly larger than Bob.

Examples input Copy 4 7 output Copy 2 input Copy 4 9 output Copy 3 input Copy 1 1 output Copy 1 Note

In the first sample, Limak weighs?4?and Bob weighs?7?initially. After one year their weights are?4·3?=?12?and?7·2?=?14?respectively (one weight is tripled while the other one is doubled). Limak isn't larger than Bob yet. After the second year weights are?36?and?28, so the first weight is greater than the second one. Limak became larger than Bob after two years so you should print?2.

In the second sample, Limak's and Bob's weights in next years are:?12?and?18, then?36?and?36, and finally?108?and?72?(after three years). The answer is?3. Remember that Limak wants to be larger than Bob and he won't be satisfied with equal weights.

In the third sample, Limak becomes larger than Bob after the first year. Their weights will be?3?and?2?then.

?

?

?

#include<iostream> using namespace std; int main(){int a;int b;cin>>a;cin>>b;int res = 0;do{res++;a*=3;b*=2;}while(a<=b);cout<<res;return 0; }

?

轉載于:https://www.cnblogs.com/godoforange/p/10944674.html

總結

以上是生活随笔為你收集整理的Codeforces A. Bear and Big Brother的全部內容,希望文章能夠幫你解決所遇到的問題。

如果覺得生活随笔網站內容還不錯,歡迎將生活随笔推薦給好友。

主站蜘蛛池模板: 五月天综合网站 | 奇米四色在线观看 | 国产成人免费视频网站 | 色牛av | 美女视频黄色 | 色 综合 欧美 亚洲 国产 | 欧美一级性生活视频 | 免费古装一级淫片潘金莲 | 亚州av片 | 亚洲在线色 | 精品国产av无码一区二区三区 | 七七久久| 国产xxxx做受视频 | 午夜黄色福利 | 久久久久99人妻一区二区三区 | 欧美一区二区三区的 | 天天操天天操天天操天天 | 阿v天堂2018| 欧美黑人巨大xxx极品 | 国产一区二区三区亚洲 | 国产乡下妇女做爰毛片 | 日韩精品国产一区 | 色五夜 | 久久久久久久影视 | caopeng视频 | 国产精品一区无码 | 性猛交╳xxx乱大交 偷偷操不一样的久久 | 一个人免费在线观看视频 | 农村少妇 | 伦乱天堂 | 黄色不打码视频 | 精品一区二区无码 | 国产精品久久久久久免费观看 | 大片av| 亚洲国产精品久久久久久6q | jizz中国女人 | 国产xxxxxxxxx| 91精品国产综合久久久蜜臀粉嫩 | 国产黄网在线观看 | 无码免费一区二区三区 | 国产精品久久久久久久裸模 | 日皮视频免费观看 | 亚欧精品视频一区二区三区 | 超碰xxx| 亚洲精品一区二区三区蜜桃 | 国产极品粉嫩 | 手机av观看| 中国在线观看免费视频 | 国产毛片久久久久久 | 在线免费激情视频 | 草莓视频在线观看入口w | 欧美 变态 另类 人妖 | 新婚之夜玷污岳丰满少妇在线观看 | 青娱乐极品视频在线 | 亚洲aa在线观看 | 日本一本二本三区免费 | www国产亚洲精品 | 国产大片中文字幕在线观看 | 吃奶在线观看 | 亚洲性少妇 | 欧美狠狠干 | a级片免费网站 | 日本zzjj | 国产精品一亚洲av日韩av欧 | 亚洲自拍偷拍综合 | 三级全黄视频 | 国产精品xxxx喷水欧美 | 欧美另类在线观看 | 国产日韩欧美 | 成人夜晚看av | 网友自拍视频 | 欧美aaaa视频 | 1000部啪啪 | 懂色av蜜臀av粉嫩av喷吹 | 在线免费观看a级片 | 天天舔天天射天天干 | 国产一区一区 | 日本韩国欧美中文字幕 | 亚洲精品影院在线 | 天堂久久av| 黄色av电影在线 | 日韩毛片高清在线播放 | 精品1区2区3区 | 国产小视频免费 | 日韩欧美www| 日本三级午夜理伦三级三 | 国产一区二区三区四区五区 | 国产精品久久毛片 | 毛片毛片毛片毛片毛片 | 毛片手机在线 | 奇米四色影视 | 日本三级中文字幕 | 成人精品久久久 | 久久久一| 亚洲免费大全 | 一区二区三区日韩 | 久久影视一区二区 | 99在线免费| 日本韩国免费观看 |