When reading a text, I start by predicting the probable meaning, then I get to read and understand the words and phrases in the text to check whether that is really what the writer means. Sometimes I go the other way round. That’s to say, I combine the above 2 ways in my reading. This is the interactive model.()
此题为判断题(对,错)。
第1题:
以下程序运行后,Text1的输出结果是___________ 。 Dim a%(5), i% For i = 0 To 5 a(i) = 2 * i + 1 Text1.Text = a(i) Next i
A.程序出错
B.1 3 5 7 9 11
C.11
D.9
E.1
第2题:
在主线程中启动一个子线程执行reading函数。 import threading import time import random def reading(): for i in range(10): print("reading",i) time.sleep(random.randint(1,2)) _______________________________ r.setDaemon(False) r.start() print("The End")
A.r=threading.Thread(reading)
B.r=threading.Thread(target=reading())
C.r=threading.Thread(target=reading)
D.r=Thread(target=reading)
第3题:
1、用于二进制读写的I/O流函数包括
A.get()
B.getline()
C.read()
D.write()
第4题:
以下代码片段执行后,text的值为:() var i=1, text=''; do { text += i; i++; } while (i < 5);
A.15
B.10
C.6
D.1234
第5题:
下面的代码用于输出字符数组ch中每个字符出现的次数,应该填入的代码是()public static void main(String[] args) { char[] ch = { 'a', 'c', 'a', 'b', 'c', 'b' }; HashMap map = new HashMap(); for (int i = 0; i < ch.length; i++) { < 填入代码 > } System.out.println(map); }
A.if (map.contains(ch[i])) { map.put(ch[i], map.get(ch[i]) + 1); } else { map.put(ch[i], 1); }
B.if (map.contains(ch[i])) { map.put(ch[i], (Integer) map.get(ch[i]) + 1); } else { map.put(ch[i], 1); }
C.if (map.containsKey(ch[i])) { map.put(ch[i], (int) map.get(ch[i]) + 1); } else { map.put(ch[i], 1); }
D.if (map.containsKey(ch[i])) { map.put(ch[i], (Integer) map.get(ch[i]) + 1); } else { map.put(ch[i], 1); }
第6题:
用于二进制读写的I/O流函数包括
A.get()
B.getline()
C.read()
D.write()