【单选题】【消耗次数:1】
对于长度为18的顺序存储的有序表,若采用折半查找,则查找第15个元素的比较次数为( )。
3
4
5
6
参考答案:
复制
纠错
相关题目
【单选题】 对于顺序存储的有序表(5,12,20,26,37,42,46,50,64),若采用折半查找,则查找元素26的比较次数为( )。
①  2
②  3
③  4
④  5
【单选题】 对于长度为9的顺序存储的有序表,若采用折半查找,在等概率情况下的平均查找长度为( )的9分之一。
①  20
②  18
③  25
④  22
【单选题】 有一个长度为7的有序表,按折半查找对该表进行查找,在等概率情况下查找成功的平均比较次数为( )。
①  A.17/7
②  B.18/7
③  C.21/7
④  D.20/7
【单选题】 有一个长度为8的有序表,按折半查找对该表进行查找,在等概率情况下查找成功的平均比较次数为( )。
①  A.22/8
②  B.20/8
③  C.23/8
④  D.21/8
【单选题】 有一个长度为11的有序表,按折半查找对该表进行查找,在等概率情况下查找成功的平均比较次数为( )。
①  A.29/11
②  B.33/11
③  C.26/11
④  D.30/11
【判断题】 有一个长度为10的有序表,按折半查找对该表进行查找,在等概率情况下查找成功的平均比较次数为29/10。
①  正确
②  错误
【单选题】 对具有n个元素的有序表采用折半查找,则算法的时间复杂度为( )。
①  O(n)
②  O(n的平方)
③  O(1)
④  O(log2(n))
【单选题】 采用顺序查找方法查找长度为n的线性表时,每个元素的平均查找长度为( )。
①  A.n
②  B.n/2
③  C.(n+1)/2
④  D.(n-1)/2
【单选题】 若查找每个元素的概率相等,则在长度为n的顺序表上查找任一元素的平均查找长度为( )。
①  n
②  n+1
③  (n-1)/2
④  (n+1)/2
【单选题】 设有一个长度为18的顺序表,要在第6个元素之前插入一个元素(也就是插入元素作为新表的第6个元素),则移动元素个数为( )。
①  A.12
②  B.5
③  C. 13
④  D.6
随机题目
【单选题】 I don’t know the place ________ he studied.
①  which
②  that
③  where
④  in where
【单选题】 Mr. Zhang, _______ we have learned a lot, is very popular among us.
①  who
②  from that
③  from whom
④  whom
【单选题】 The biggest day ____________ I’ve ever been to is Beijing.
①  where
②  that
【单选题】 I don’t know the reason ___________ she is absent again today.
①  that
②  why
【单选题】 The boy worked hard ______ he could get the prize.
①  so that
②  so as to
③  so as
④  in order to
【单选题】 _______ my parents refused to support me, I have to earn money by myself.
①  When
②  Even
③  Since
④  So
【单选题】 Doris kept reading the poem ______ she could bear it in her mind.
①  until
②  unless
③  when
④  and
【单选题】 He left home without ______ any message to his parents.
①  leaving
②  leave
【单选题】 You can take any apple ____________ you like.
①  that
②  which
【单选题】 The house __________ he used to live in is a library now.
①  which
②  where