楼主: zht505540914
1734 1

[作业] 数据结构与算法分析 Java语言描述 原书第三版 韦斯 WEISS 习题答案 源码 [推广有奖]

  • 0关注
  • 2粉丝

等待验证会员

已卖:366份资源

讲师

14%

还不是VIP/贵宾

-

威望
0
论坛币
3 个
通用积分
0.5509
学术水平
0 点
热心指数
0 点
信用等级
0 点
经验
5024 点
帖子
175
精华
0
在线时间
205 小时
注册时间
2019-4-19
最后登录
2025-7-31

楼主
zht505540914 在职认证  发表于 2019-4-20 00:00:32 |AI写论文

+2 论坛币
k人 参与回答

经管之家送您一份

应届毕业生专属福利!

求职就业群
赵安豆老师微信:zhaoandou666

经管之家联合CDA

送您一个全额奖学金名额~ !

感谢您参与论坛问题回答

经管之家送您两个论坛币!

+2 论坛币
数据结构与算法分析 Java语言描述 原书第三版 韦斯 WEISS 习题答案 源码

1555688998(1).png







CHAPTER 2
Algorithm Analysis
2.1        2/N, 37, , N, N log log N, N log N, N log(N2), N log2 N, N1.5, N2, N2 log N, N3, 2N/2, 2N.
N log N and N log (N2) grow at the same rate.
2.2        (a) True.
         (b) False. A counterexample is T1(N) = 2N, T2(N) = N, and f (N) = N.
         (c) False. A counterexample is T1(N) = N2, T2(N) = N, and f (N) = N2.
         (d) False. The same counterexample as in part (c) applies.
2.3        We claim that N log N is the slower growing function. To see this, suppose otherwise. Then,  would grow slower than log N. Taking logs of both sides, we find that, under this assumption,  grows slower than log log N. But the first expression simplifies to  If L = log N, then we are claiming that  grows slower than log L, or equivalently, that 2L grows slower than log2 L. But we know that log2 L = o(L), so the original assumption is false, proving the claim.
2.4        Clearly,  if k1 < k2, so we need to worry only about positive integers. The claim is clearly true for k&nbsp;=&nbsp;0 and k&nbsp;=&nbsp;1. Suppose it is true for k < i. Then, by L’H&ocirc;pital’s rule,

         The second limit is zero by the inductive hypothesis, proving the claim.
2.5        Let f(N)&nbsp;=&nbsp;1 when N is even, and N when N is odd. Likewise, let g(N)&nbsp;=&nbsp;1 when N is odd, and N when N is even. Then the ratio f(N)/g(N) oscillates between 0 and inf.
答案如上
预览更多加我V信:ID
答案为本人自己创作,如有雷同,纯属巧合
本文来自: 人大经济论坛 现金交易版 版,详细出处参考: https://bbs.pinggu.org/forum.php ... mp;from^^uid=11596612 Chapter01.doc (69.5 KB)
二维码

扫码加我 拉你入群

请注明:姓名-公司-职位

以便审核进群资格,未注明则拒绝


完整答案获取方式.doc
下载链接: https://bbs.pinggu.org/a-2794472.html

9.5 KB

Chapter02.doc

69.5 KB

沙发
wangyong8935 在职认证  发表于 2019-10-18 13:55:58
thank you for sharing

您需要登录后才可以回帖 登录 | 我要注册

本版微信群
jg-xs1
拉您进交流群
GMT+8, 2026-1-10 21:56