Array and Loops in Visual Basic Net?

Paperpen

New member
Dim a(10) As Integer

For i As Integer = 1 To 5
a(i) = i + a(i – 1)
a(i * 2 – 1) = a(i) * 2
Next
Debug.Print(a(3))


Please kindly first tell me what will be the output? And please give some reasons like how to approach it line by line.
 
Back
Top