单选题
VB
题号 #1759378
设有分段函数:

以上表示上述分段函数的语句序列中错误的是:( )。
A.Select Case x
Case Is<0
Y=5
Case Is <=5,Is>0
Y=2*x
Case else
End select
B.If x<0 Then
y=5
Elseif x<=5 then
y=2*x
Else
y=x*x+1
End if
C.y=iif{x<0.5,iif(x<=5.2*x,x*x+1) }
D.If x<0 Then y=5
If x<=5 and x>=0 then y=2*x
If x>5 then y=x*x+1
参考答案
A
答案解析
A)项中第二个case子句中is<=5,is>0将x=0的情况给丢掉了,因此A)项是正确答案。
你可能感兴趣的试题
A.0
B.5
C.100
D.空白
A.9753
B.3579
C.35
D.79