皮皮学,免费搜题
登录
logo - 刷刷题
搜题
【单选题】
以下程序执行后的输出结果是: #include using namespace std; class A{ public: void Print(){cout< }; class B: public A { public: void Print(){cout< } }; int main() { A a,*pa; B b; pa=&a; pa->Print(); pa=&b; pa->Print(); return 0; }
A.
AA
B.
AB
C.
BB
D.
BA
手机使用
分享
复制链接
新浪微博
分享QQ
微信扫一扫
微信内点击右上角“…”即可分享
反馈
参考答案:
举一反三
【单选题】下面代码的输出结果是 ‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬ a = [[1,2,3], [4,5,6], [7,8,9]] s = 0 for c in a: for j in range(3): s += c[j] print(s)
A.
24
B.
0
C.
45
D.
以上答案都不对
【单选题】中暑患者的灌肠溶液温度为:
A.
4℃
B.
5℃
C.
6℃
D.
7℃
E.
8℃
【单选题】文件 book.txt 在当前程序所在目录内,其内容是一段文本:book,下面代码的输出结果是‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬( )txt=open("book.txt","r")print(txt)txt.close()
A.
以上答案都不对
B.
book
C.
txt
D.
book.txt
【简答题】二层交换机之所以称为二层,是因为数据交换在( )实现的。
【单选题】如果当前时间是 2018年5月1日10点10分9秒,则下面代码的输出结果是 ‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬ import time print(time.strftime("%Y=%m-%d@%H>%M>%S", time.gmtime()))
A.
2018=5-1@10>10>9
B.
05-01@10>10>09
C.
2018=5-1 10>10>9
D.
True@True
【单选题】下面代码的输出结果是 ‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬ s =["seashell","gold","pink","brown","purple","tomato"] print(s[1:4:2]) ‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬
A.
['gold', 'brown']
B.
['gold', 'pink', 'brown']
C.
['gold', 'brown', 'tomato']
D.
['gold', 'pink', 'brown', 'purple', 'tomato']
【判断题】元代因为地域广大,各地情况各异,规定司法的各个环节可以因地制宜,不必强求一致。
A.
正确
B.
错误
【单选题】“她差点儿迟到了"意思是( )
A.
她迟到了
B.
她刚刚迟到
C.
不确定她迟到了吗
D.
她没迟到
【单选题】文件 book.txt 在当前程序所在目录内,其内容是一段文本:book,下面代码的输出结果是 ‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬ txt = open("book.txt", "r") print(txt) txt.close()
A.
book
B.
book.txt
C.
txt
D.
以上答案都不对
【单选题】当用户输入 abc时,下面代码的输出结果是 ‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬‬ try: n = 0 n = input("请输入一个整数: ") def pow10(n): return n**10 except: print("程序执行错误")
A.
输出:程序执行错误
B.
输出: abc
C.
程序没有任何输出
D.
输出: 0
相关题目:
参考解析:
知识点:
题目纠错 0
发布
创建自己的小题库 - 刷刷题