Two Dimensional Rectangle Array : Array Multi Dimension « Data Structure « VB.Net

VB.Net
1. 2D
2. Application
3. Class
4. Data Structure
5. Database ADO.net
6. Development
7. Event
8. File Directory
9. Generics
10. GUI
11. Language Basics
12. Network Remote
13. Thread
14. Windows System
15. XML
Microsoft Office Word 2007 Tutorial
Java
Java Tutorial
Java Source Code / Java Documentation
Java Open Source
Jar File Download
Java Articles
Java Products
Java by API
C# / C Sharp
C# / CSharp Tutorial
ASP.Net
JavaScript DHTML
JavaScript Tutorial
JavaScript Reference
HTML / CSS
HTML CSS Reference
C / ANSI-C
C Tutorial
C++
C++ Tutorial
PHP
Python
SQL Server / T-SQL
Oracle PL / SQL
Oracle PL/SQL Tutorial
PostgreSQL
SQL / MySQL
MySQL Tutorial
VB.Net Tutorial
VB.Net » Data Structure » Array Multi DimensionScreenshots 
Two Dimensional Rectangle Array
Two Dimensional Rectangle Array

Imports System

Public Class MainClass

    Shared Sub Main(ByVal args As String())
         Const rowsUB As Integer = 4
         Const columnsUB As Integer = 3

         ' declare a 4x3 Integer array
         Dim rectangularArray(rowsUB, columnsUBAs Integer

         ' populate the array
         Dim As Integer
         For i = To rowsUB - 1
             Dim As Integer
             For j = To columnsUB - 1
                 rectangularArray(i, j= i + j
             Next j
         Next i
         ' report the contents of the array
         For i = To rowsUB - 1
             Dim As Integer
             For j = To columnsUB - 1
                 Console.WriteLine_
                   "rectangularArray[{0},{1}] = {2}", _
                   i, j, rectangularArray(i, j))
             Next j
         Next i
    End Sub

End Class

           
       
Related examples in the same category
1. Initializing a jagged array, one in which the length of each array differsInitializing a jagged array, one in which the length of each array differs
2. Define and initialize the multi-dimensional arrayDefine and initialize the multi-dimensional array
3. Seclare a 4x3 Integer arraySeclare a 4x3 Integer array
4. Array Performance Test: Two-dimensional arrayArray Performance Test: Two-dimensional array
5. Array Performance Test: Two-dimensional Array and SetValue(i, i)Array Performance Test: Two-dimensional Array and SetValue(i, i)
6. Define and Init two dimensional arrayDefine and Init two dimensional array
7. Initializing multidimensional arrays: rectangular two-dimensional arrayInitializing multidimensional arrays: rectangular two-dimensional array
8. Jagged two-dimensional arrayJagged two-dimensional array
9. Two dimension array DemoTwo dimension array Demo
w___w___w.___j__ava___2___s__.co_m_ | Contact Us
Copyright 2003 - 08 Demo Source and Support. All rights reserved.
All other trademarks are property of their respective owners.