012章 绪论+向量

02E-2 QUIZ

Which situation will the improved blistering order will end prematurely ? 
经改进的起泡排序在什么情况下会提前结束?

 

EXPLANATION

Another statement is: No element exchange occurs in a scan switch 
另一个说法是:某趟扫描交换中没有发生元素交换

02-D3-3 QUIZ

V={1, 2, 3, 4, 5, 6, 7}, using Fibonacci to find element 1 in V, the element selected as the pivot point mi is:
V={1, 2, 3, 4, 5, 6, 7},在V中用Fibonacci查找元素1,被选取为轴点mi的元素依次是:

 
Rank mi = lo + fib.get() - 1;

是元素不是索引

 

实例A

V={2, 3, 5, 7, 11, 13, 17}. How many comparisons V.search(16, 0, 7) need to make? 
V={2, 3, 5, 7, 11, 13, 17}。V.search(16, 0, 7)需要进行多少次比较?

 
lo = 0, hi = 7;

hi在区间外!!

--------------------------------------------

01B-5: 图灵机

Which of the following is NOT a component of a Turing machine? 以下哪项不是图灵机的组成要件?

01-E-5: 数组倒置

The base cases of a recursive function are degenerated cases, without which the sequence of recursive function calls would go forever.

01XC-2: FIB():递推方程

The naive way of computing fib(n) recursively leads to a time complexity of 
直接用定义以递归的方式计算fib(n)的时间复杂度是:

 
posted @ 2019-03-14 00:04  yeoreum  阅读(461)  评论(0编辑  收藏  举报