A.missing
B.lost
第1题:
A.write, calls
B. wrote, called
C.was writing, calls
D. was writing, called
第2题:
第3题:
第4题:
使用VC6打开考生文件夹下的工程test37_1,此工程包含一个源程序文件test37_1.cpp,但该程序运行有问题,请改正函数中的错误,使该程序的输出结果为:
0149 16 25 36 49 64 81
源程序文件test37_1.cpp清单如下:
include<iostream.h>
template <class T, int N = 100> class Vector
{
T vec[N];
public:
void set(int pos, T val);
T get(iht pos);
/***************** found *****************/
}
template <class T, int N> void Vector<T, N>::set(int pos, T val)
{
vec[pos] = val;
}
/***************** found *****************/
template <class T, int N> Vector<T, N>::get(int pos)
{
return vec[pos];
}
int main ()
{
Vector<double, 10> v;
int i = 0;
double d = 0.0;
for (i = 0; i < 10; i++)
v.set(i, double(i * i));
for (i = 0; i < 10; i++)
cout<<v.get(i)<<" ";
cout<<end1;
/***************** found *****************/
}
第5题:
第6题:
20、以下程序的输出结果是()? letter = ['A','B', 'C', 'D', 'D'] for i in letter: if i == 'D': letter.remove(i) print(letter)
A.['A','B', 'C', 'D']
B.['A','B', 'C', 'D','D']
C.['A','B', 'C', 'D','D','D']
D.['A','B', 'C']