Private Sub Command1_Click()
x = InputBox("请输入x:")
e = 2.718281828
Select Case x
Case -10 To -1
y = e ^ x + 1
Case 0 To 5
y = Abs(x ^ 2 - 100)
Case 6 To 9
y = 3 * x ^ 3 - 2 * x ^ 2 - x + 1
End Select
Print y
End Su
Private Sub Command1_Click()
x = InputBox("请输入x:")
e = 2.718281828
Select Case x
Case -10 To -1
y = e ^ x + 1
Case 0 To 5
y = Abs(x ^ 2 - 100)
Case 6 To 9
y = 3 * x ^ 3 - 2 * x ^ 2 - x + 1
End Select
Print y
End Su