Dim i As Short = 1
Do
Dim j As Short = 1
Do
Dim money As Integer = 5 * i + 10 * i + 2 * j
If money = 400 Then
MsgBox(i & " " & j)
ElseIf money > 400 Then
Exit Do
End If
j += 1
Loop
i += 1
Loop
Do
Dim j As Short = 1
Do
Dim money As Integer = 5 * i + 10 * i + 2 * j
If money = 400 Then
MsgBox(i & " " & j)
ElseIf money > 400 Then
Exit Do
End If
j += 1
Loop
i += 1
Loop