阅读以下程序,则y=()。x=[4,-9,25];ifx<0disp('someoftheelementsofxarenegative.')elsey=sqrt(x)end
A. 2.0000+0.0000i 0.0000+3.0000i 5.0000+0.0000i
B. 2.0000 3.0000 5.0000
C. 2.0000-1.0000i 3.0000 5.0000
D. 2.0000 3.0000 5.0000i
查看答案
阅读以下程序,则y=()。x=[4,-9,25];if x>=0y=sqrt(x)elsedisp('someoftheelementsofxarenegative.')end
A. 2.0000 3.0000i 5.0000
B. 2.0000 3.0000 5.0000
C. some of the elements of x are negative.
D. 2.0000 3.0000 5.0000i
阅读下面程序,则disp语句所显示结果为()。x=1;while x~=5disp(x)x=x+1;end
A. 1 3 2 4
B. 1 2 3 4
C. 2 3 4 5
D. 1 3 4 2
阅读下面的程序,则x的取值为()。x=8;while x~=0x=x-3;end
A. 1952-01-04
B. 1952-01-03
C. 52-1-4......
D. 不显示任何内容,死循环
阅读下面的程序,则x的取值为()。fork=5:10:35x=k^2end
A. 25 225 625 1225
B. 25 225 49 64
C. 25 36 49 64
D. 25 225455625