问答题
求下面算法中变量count的值:(假设n为2的乘幂,并且n>2)
int Time
int n
count=0;x=2;
while(x<n/2)
x
*
=2;count++;
return(count)
【参考答案】
count=log
2
n
点击查看答案
<上一题
目录
下一题>
热门
试题
问答题
head(tail(L1))
点击查看答案
问答题
图的邻接表的类型定义如下所示: #define MaxVertexNum 50 typedef struct node int adjvex; struct node*next; EdgeNode; typedef struct VertexType vertex; EdgeNode*firstedge; VertexNode; typedef VertexNode A djList[MaxVertexNum]; typedef struct AdjList adjiist; int n,e;
点击查看答案
相关试题
如果二叉排序树T中存在含有关键字大于给定...
T是空树或T中所有结点的关键字均不大于给定...
head(head(tail(head(L2))))
J
写出向某个有序文件中插入一个记录的程序。