.NET自由天空
Would you like to react to this message? Create an account in a few clicks or log in to continue.

作业-商场购物.猜字游戏.闰年..............

向下

作业-商场购物.猜字游戏.闰年.............. Empty 作业-商场购物.猜字游戏.闰年..............

帖子  赵鹏健-07网4 周二 三月 18, 2008 10:28 pm

Sub Main()
Dim a As Integer
a = Console.ReadLine()
If a Mod 4 = 0 And a Mod 100 <> 0 Then
Console.WriteLine("是闰年")
Else
Console.WriteLine("不是闰年")
End If
End Sub

End Module






Sub Main()
Dim a As Integer
a = Console.ReadLine

If a < 1000 Then
Console.WriteLine("不打折")


ElseIf a >= 1000 And a < 2000 Then
Console.WriteLine(a * 0.95)

ElseIf a >= 2000 And a < 3000 Then
Console.WriteLine(a * 0.9)
ElseIf a >= 3000 And a < 5000 Then
Console.WriteLine(a * 0.85)

ElseIf a >= 5000 Then
Console.WriteLine(a * 0.Cool
End If
End Sub




Sub Main()
Const a = 2, b = 1, c = 4
Dim e, f, g As String
Console.WriteLine("猜第一位")
e = Console.ReadLine()
If e = a Then
Console.WriteLine("猜第二位")
f = Console.ReadLine()
End If

If f = b Then
Console.WriteLine("猜第三位")
g = Console.ReadLine
End If

If g = c Then
Console.WriteLine("恭喜!密码被你破译")

End If
Console.WriteLine("失败")

End Sub

End Module bounce bounce bounce

赵鹏健-07网4

帖子数 : 1
注册日期 : 08-03-18

返回页首 向下

返回页首


 
您在这个论坛的权限:
不能在这个论坛回复主题