欢迎来到起遇信息学
起遇信息学正处于上线筹建阶段,以下功能已全部开放免费体验: ✅ 完整题库浏览与代码提交评测(C / C++ / Python / Java 等) ✅ 入门到进阶的系列课程试读、作业与考试 ✅ AI 提示、AI 作业分析等智能助教功能 ✅ 赛事模拟与个人能力报告 ✅ 邮箱注册开放 ⏳ 付费课程订阅与微信/支付宝支付通道 ⏳ 手机号登录,微信扫码登录、微信公众号绑定 使用中如遇任何问题,欢迎通过页面底部 **"联系我们"** 与我们沟通。
CF1337B.Kana and Dragon Quest game
Kana and Dragon Quest game
Kana was just an ordinary high school girl before a talent scout discovered her. Then, she became an idol. But different from the stereotype, she is also a gameholic.
One day Kana gets interested in a new adventure game called Dragon Quest. In this game, her quest is to beat a dragon.

The dragon has a hit point of initially. When its hit point goes to or under , it will be defeated. In order to defeat the dragon, Kana can cast the two following types of spells.
-
Void AbsorptionAssume that the dragon's current hit point is , after casting this spell its hit point will become . Here denotes divided by two, rounded down.
-
Lightning StrikeThis spell will decrease the dragon's hit point by . Assume that the dragon's current hit point is , after casting this spell its hit point will be lowered to .
Due to some reasons Kana can only cast no more than Void Absorptions and Lightning Strikes. She can cast the spells in any order and doesn't have to cast all the spells. Kana isn't good at math, so you are going to help her to find out whether it is possible to defeat the dragon.
Input
The first line contains a single integer () — the number of test cases.
The next lines describe test cases. For each test case the only line contains three integers , , (, ) — the dragon's intitial hit point, the maximum number of Void Absorptions and Lightning Strikes Kana can cast respectively.
Output
If it is possible to defeat the dragon, print "YES" (without quotes). Otherwise, print "NO" (without quotes).
You can print each letter in any case (upper or lower).
Note
One possible casting sequence of the first test case is shown below:
Void Absorption.Lightning Strike.Void Absorption.Void Absorption.Lightning Strike.Lightning Strike.Lightning Strike.
Samples
7
100 3 4
189 3 4
64 2 3
63 2 3
30 27 7
10 9 1
69117 21 2
YES
NO
NO
YES
YES
YES
YES
在线编程 IDE
建议全屏模式获得最佳体验
| 进入全屏编程 | Alt+E |
| 递交评测 | Ctrl+Enter |
| 注释/取消注释 | Ctrl+/ |
| 缩放字体 | Ctrl+滚轮 |