| Option Strict On
Option Explicit On
Module ArrayDemo
Sub Main()
Dim table(9) as Integer ' indexing from 0 to 9.
For i as Integer = 0 To 9
table(i) = i * i
Next
For i as Integer = 0 To 9
Console.WriteLine(table(i))
Next
End Sub
End Module |
|
| | A Visual Basic Program with an array of 10 elements.
|