Private Sub Form_Load()Dim a, bOpen App.Path & "\in.txt" For Input As #1Input #1, bDo While Not EOF(1)Input #1, aIf a < b Then b = aLoopClose #1Open App.Path & "\out.txt" For Output As #2Print #2, bCloseEnd Sub感覺這是最簡單的一題~
歡迎新的開始,arro, 一路向前,累積簡單的題目,也是需要的。比賽的題目,常常還是會有基本分的題目的。 這題OK。 熊掌
Private Sub Form_Load()Open App.Path & "\in.txt" For Input As #1Input #1, ix = iDo Until EOF(1)Input #1, iIf x > i Then x = iLoopOpen App.Path & "\out.txt" For Output As #2Print #2, xClose #2Close #1End Sub
緣尉好, 歡迎加入,要有企圖心,路遙知馬力,加油。 這題OK。 熊掌
Private Sub Form_Load()
回覆刪除Dim a, b
Open App.Path & "\in.txt" For Input As #1
Input #1, b
Do While Not EOF(1)
Input #1, a
If a < b Then b = a
Loop
Close #1
Open App.Path & "\out.txt" For Output As #2
Print #2, b
Close
End Sub
感覺這是最簡單的一題~
歡迎新的開始,arro,
回覆刪除一路向前,累積簡單的題目,也是需要的。比賽的題目,常常還是會有基本分的題目的。
這題OK。
熊掌
Private Sub Form_Load()
回覆刪除Open App.Path & "\in.txt" For Input As #1
Input #1, i
x = i
Do Until EOF(1)
Input #1, i
If x > i Then x = i
Loop
Open App.Path & "\out.txt" For Output As #2
Print #2, x
Close #2
Close #1
End Sub
緣尉好,
回覆刪除歡迎加入,要有企圖心,路遙知馬力,加油。
這題OK。
熊掌