Monday 29 August 2011

Block scope

Option Strict On

Public Class BlockScope
   Public Shared Sub Main()
   
      For outerLoop As Integer = to 10000
         For innerLoop As Integer = to 10
            Dim blockVar As Integer
            blockVar += 1
            If blockVar Mod 1000 Then 
                Console.WriteLine(blockVar)
            End If
         Next
      Next
   
   End Sub
End Class

No comments:

Post a Comment