Imports System
Public Module Module1
Public Sub Main()
dim a as integer
dim max as integer
dim min as integer
Dim id As String
id=" "
max=console.ReadLine()
min=max
While id <> "f"
console.WriteLine("請輸入數字")
a=console.ReadLine()
if a > max then
max=a
end if
if a < min then
min=a
console.WriteLine("f結束,enter繼續")
id=console.ReadLine()
End While
console.WriteLine("最大值:"&max)
console.WriteLine("最小值:"&min)
End Sub
End Module