forked from Sergio0694/FizzBuzz
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathProgram.vb
More file actions
24 lines (23 loc) · 708 Bytes
/
Program.vb
File metadata and controls
24 lines (23 loc) · 708 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
Imports System
Namespace FizzBuzz
Module Program
Sub Main()
For i = 1 To 100
Dim textToPrint as String = ""
Dim printNumber As Boolean = True
If i Mod 3 = 0 Then
textToPrint = "Fizz"
printNumber = False
End If
If i Mod 5 = 0 Then
textToPrint += "Buzz"
printNumber = False
End If
If printNumber Then
textToPrint = i
End If
Console.WriteLine(textToPrint)
Next
End Sub
End Module
End Namespace