ChaseDream
搜索
返回列表 发新帖
查看: 724|回复: 2
打印 上一主题 下一主题

請教OG - DS #115

[复制链接]
跳转到指定楼层
楼主
发表于 2012-2-13 21:21:41 | 只看该作者 回帖奖励 |倒序浏览 |阅读模式
For any intergers X and Y , min(X,Y) and max(X,Y) denote the minimum and the maximum of X and Y, respectively. For example, min(5,2) =2 and max(5,2)=5. For the integer W, what it the value of min (10, W) ?

1. W=max (20,Z) for some integer Z.
2. W=max (10,W)

Ans: D

我不懂的是 條件(1)下 W=max (20,Z)的Z不確定 , 怎麼可以確知 W>=20, Z 難道不會是最max?

先謝謝各位LZ了~~~
收藏收藏 收藏收藏
沙发
发表于 2012-2-13 22:06:24 | 只看该作者
question asks which one is bigger, 10 or W?

1) W is bigger than 20 because it equals to max (20, Z). Sufficient because it doesn't matter what Z is, the max of (20, Z) cannot be smaller than 20, For example, if Z is 10, then max (20, Z) is 20, if Z>20, then the max of (20, Z) is > 20...  therefore W > 20 > 10

2) same
板凳
 楼主| 发表于 2012-2-13 22:34:19 | 只看该作者
haha...I got it!
您需要登录后才可以回帖 登录 | 立即注册

Mark一下! 看一下! 顶楼主! 感谢分享! 快速回复:

手机版|ChaseDream|GMT+8, 2025-9-8 17:01
京公网安备11010202008513号 京ICP证101109号 京ICP备12012021号

ChaseDream 论坛

© 2003-2025 ChaseDream.com. All Rights Reserved.

返回顶部