一道vb题目Private Sub Command1_Click() x = -5 If Sgn(x + 5) Then y = Sgn(x + 2) * Sgn(x - 2) Else y = Sgn(x) End If Print yEnd Sub为什么算到 Sgn(x + 5)时就跳到 y = Sgn(x)算了呢?怎么算的啊?急用啊
来源:学生作业帮助网 编辑:作业帮 时间:2024/12/01 02:50:08
x){e䲤f<.(,$U!4I9?771/09'39[CSABVATA3M!8=OBA[TS!$#5O*0a#M-(GQp)NEQK@kJ*A@dwÓMڱɮgӷ=ݰ aQ@uOv=YCDY-OvKOYd$,`0_C9^J?T
(0e
':`A_`g3DqzϦn *t"-` $ف G
一道vb题目Private Sub Command1_Click() x = -5 If Sgn(x + 5) Then y = Sgn(x + 2) * Sgn(x - 2) Else y = Sgn(x) End If Print yEnd Sub为什么算到 Sgn(x + 5)时就跳到 y = Sgn(x)算了呢?怎么算的啊?急用啊
一道vb题目
Private Sub Command1_Click()
x = -5
If Sgn(x + 5) Then
y = Sgn(x + 2) * Sgn(x - 2)
Else
y = Sgn(x)
End If
Print y
End Sub
为什么算到 Sgn(x + 5)时就跳到 y = Sgn(x)算了呢?怎么算的啊?
急用啊
一道vb题目Private Sub Command1_Click() x = -5 If Sgn(x + 5) Then y = Sgn(x + 2) * Sgn(x - 2) Else y = Sgn(x) End If Print yEnd Sub为什么算到 Sgn(x + 5)时就跳到 y = Sgn(x)算了呢?怎么算的啊?急用啊
sgn函数
x>0,sgnx=1
x=0,sgnx= 0
x