下列程序段的执行结果是( )。 x = 5: y = 7: z = 8 If x < y Then t = x: x = y: y = t End If If y < z Then t = y: y = z: z = t If x < y Then t = x: x = y: y = t End If End If Print x, y, z A: 8 5 7 B: 8 7 5 C: 5 7 8 D: 7 5 8
下列程序段的执行结果是( )。 x = 5: y = 7: z = 8 If x < y Then t = x: x = y: y = t End If If y < z Then t = y: y = z: z = t If x < y Then t = x: x = y: y = t End If End If Print x, y, z A: 8 5 7 B: 8 7 5 C: 5 7 8 D: 7 5 8
>>>x= [10, 6, 0, 1, 7, 4, 3, 2, 8, 5, 9]>>>print(x.sort()) 语句运行结果正确的是( )。 A: [0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10] B: [10, 6, 0, 1, 7, 4, 3, 2, 8, 5, 9] C: [10, 9, 8, 7, 6, 5, 4, 3, 2, 1, 0] D: ['2', '4', '0', '6', '10', '7', '8', '3', '9', '1', '5']
>>>x= [10, 6, 0, 1, 7, 4, 3, 2, 8, 5, 9]>>>print(x.sort()) 语句运行结果正确的是( )。 A: [0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10] B: [10, 6, 0, 1, 7, 4, 3, 2, 8, 5, 9] C: [10, 9, 8, 7, 6, 5, 4, 3, 2, 1, 0] D: ['2', '4', '0', '6', '10', '7', '8', '3', '9', '1', '5']
【计算题】5 ×8= 6×4= 7×7= 9×5= 2×3= 9 ×2= 8×9= 7×8= 5×5= 4×3= 5+8= 6 ×6= 3×7= 4×8= 9×3= 1 ×2= 9×9= 6×8= 8×0= 4×7=
【计算题】5 ×8= 6×4= 7×7= 9×5= 2×3= 9 ×2= 8×9= 7×8= 5×5= 4×3= 5+8= 6 ×6= 3×7= 4×8= 9×3= 1 ×2= 9×9= 6×8= 8×0= 4×7=
已知a=[1 2 3; 4 5 6; 7 8 9],执行命令:a([3,1],:)=a([1,3],:),a将变为( )。 A: [4 5 6;4 5 6;4 5 6] B: [7 8 9;4 5 6;1 2 3] C: [2 2 2;5 5 5;8 8 8] D: [3 2 1;6 5 4;9 8 7]
已知a=[1 2 3; 4 5 6; 7 8 9],执行命令:a([3,1],:)=a([1,3],:),a将变为( )。 A: [4 5 6;4 5 6;4 5 6] B: [7 8 9;4 5 6;1 2 3] C: [2 2 2;5 5 5;8 8 8] D: [3 2 1;6 5 4;9 8 7]
set1 = {x for x in range(10)} print(set1) 以上代码的运行结果为? A: {0, 1, 2, 3, 4, 5, 6, 7, 8, 9} B: {0, 1, 2, 3, 4, 5, 6, 7, 8, 9,10} C: {1, 2, 3, 4, 5, 6, 7, 8, 9} D: {1, 2, 3, 4, 5, 6, 7, 8, 9,10}
set1 = {x for x in range(10)} print(set1) 以上代码的运行结果为? A: {0, 1, 2, 3, 4, 5, 6, 7, 8, 9} B: {0, 1, 2, 3, 4, 5, 6, 7, 8, 9,10} C: {1, 2, 3, 4, 5, 6, 7, 8, 9} D: {1, 2, 3, 4, 5, 6, 7, 8, 9,10}
intx=5,y=8,z=7;表达式z=!(x>y)||(x=1,y=3)计算后的结果 A: x=1,y=3,z=1 B: x=1,y=3,z=0 C: x=5,y=8,z=0 D: x=5,y=8,z=1
intx=5,y=8,z=7;表达式z=!(x>y)||(x=1,y=3)计算后的结果 A: x=1,y=3,z=1 B: x=1,y=3,z=0 C: x=5,y=8,z=0 D: x=5,y=8,z=1
存在多维数组arr,arr =np.array([[1 2 3] [4 5 6] [7 8 9]])数组arr.T的输出为 A: array([[1, 4, 7], [2, 5, 8], [3, 6, 9]]) B: array([[1, 2, 3], [4, 5, 8], [7, 6, 9]]) C: array([[1, 4, 7], [2, 5, 6], [3, 8, 9]]) D: array([[9, 4, 7], [2, 5, 8], [3, 6, 1]])
存在多维数组arr,arr =np.array([[1 2 3] [4 5 6] [7 8 9]])数组arr.T的输出为 A: array([[1, 4, 7], [2, 5, 8], [3, 6, 9]]) B: array([[1, 2, 3], [4, 5, 8], [7, 6, 9]]) C: array([[1, 4, 7], [2, 5, 6], [3, 8, 9]]) D: array([[9, 4, 7], [2, 5, 8], [3, 6, 1]])
设X,Y为两个随机变量,且P{X ³0,Y ³ 0} = 3/7 , P{X ³ 0} = P{ Y ³ 0} = 4/7 ,则P{max(X, Y) ³ 0} = ( ). A: 1/7 B: 3/7 C: 4/7 D: 5/7
设X,Y为两个随机变量,且P{X ³0,Y ³ 0} = 3/7 , P{X ³ 0} = P{ Y ³ 0} = 4/7 ,则P{max(X, Y) ³ 0} = ( ). A: 1/7 B: 3/7 C: 4/7 D: 5/7
下列代码哪行会出错: 1) public void modify() { 2) int I, j, k; 3) I = 100; 4) while ( I > 0 ) { 5) j = I * 2; 6) System.out.println (” The value of j is ” + j );7) k = k + 1; 8) I–; 9) } 10) } A: 4 B: 6 C: 7 D: 8
下列代码哪行会出错: 1) public void modify() { 2) int I, j, k; 3) I = 100; 4) while ( I > 0 ) { 5) j = I * 2; 6) System.out.println (” The value of j is ” + j );7) k = k + 1; 8) I–; 9) } 10) } A: 4 B: 6 C: 7 D: 8
4、下列代码( )会出错。1) public void modify() {2) int I, j, k;3) I = 100;4) while ( I >; 0 ) {5)j = I * 2;6) System.out.println (" The value of j is " + j );7) k = k + 1;8) I--;9) }10} A: line 4 B: line 6 C: line 7 D: line 8
4、下列代码( )会出错。1) public void modify() {2) int I, j, k;3) I = 100;4) while ( I >; 0 ) {5)j = I * 2;6) System.out.println (" The value of j is " + j );7) k = k + 1;8) I--;9) }10} A: line 4 B: line 6 C: line 7 D: line 8