Initialize a two-dimensional array : Array Dimension « Collections Data Structure « C# / C Sharp

C# / C Sharp
1. 2D Graphics
2. Class Interface
3. Collections Data Structure
4. Components
5. Data Types
6. Database ADO.net
7. Design Patterns
8. Development Class
9. Event
10. File Stream
11. Generics
12. GUI Windows Form
13. Language Basics
14. LINQ
15. Network
16. Office
17. Reflection
18. Regular Expressions
19. Security
20. Services Event
21. Thread
22. Web Services
23. Windows
24. XML
25. XML LINQ
Java
Java Tutorial
Java Source Code / Java Documentation
Java Open Source
Jar File Download
Java Articles
Java Products
Java by API
Photoshop Tutorial
C# / CSharp Tutorial
C# / CSharp Open Source
ASP.Net
ASP.NET Tutorial
JavaScript DHTML
JavaScript Tutorial
JavaScript Reference
HTML / CSS
HTML CSS Reference
C / ANSI-C
C Tutorial
C++
C++ Tutorial
Ruby
PHP
Python
Python Tutorial
Python Open Source
SQL Server / T-SQL
SQL Server / T-SQL Tutorial
Oracle PL / SQL
Oracle PL/SQL Tutorial
PostgreSQL
SQL / MySQL
MySQL Tutorial
VB.Net
VB.Net Tutorial
Flash / Flex / ActionScript
VBA / Excel / Access / Word
XML
XML Tutorial
Microsoft Office PowerPoint 2007 Tutorial
Microsoft Office Excel 2007 Tutorial
Microsoft Office Word 2007 Tutorial
C# / C Sharp » Collections Data Structure » Array DimensionScreenshots 
Initialize a two-dimensional array
Initialize a two-dimensional array

// Initialize a two-dimensional array. 
 
using System; 
 
public class Squares {  
  public static void Main() {  
    int[,sqrs = 
      1}
      2}
      3}
      416 }
      525 }
      636 }
      749 }
      864 }
      981 }
      10100 
    }
    int i, j; 
 
    fori = 0; i < 10; i++) {  
      for(j = 0; j < 2; j++)  
        Console.Write(sqrs[i,j" ");   
      Console.WriteLine();  
    }  
  }  
}

           
       
Related examples in the same category
1. Demonstrate a two-dimensional arrayDemonstrate a two-dimensional array
2. Sum the values on a diagonal of a 3x3x3 matrixSum the values on a diagonal of a 3x3x3 matrix
3. Demonstrate jagged arraysDemonstrate jagged arrays
4. Use the Length array property on a 3-D arrayUse the Length array property on a 3-D array
5. Call GetLength for two dimenional array
6. Demonstrate Length with jagged arraysDemonstrate Length with jagged arrays
7. illustrates the use of a two-dimensional rectangular arrayillustrates the use of a two-dimensional rectangular array
8. initialize a two-dimensional rectangular array, and use the array properties and methodsinitialize a two-dimensional rectangular array, and use the array properties and methods
9. the use of a three-dimensional rectangular arraythe use of a three-dimensional rectangular array
10. the use of a jagged arraythe use of a jagged array
11. Uses a two-dimensional array to store grades for studentsUses a two-dimensional array to store grades for students
12. Uses a jagged array to store sales figuresUses a jagged array to store sales figures
13. Multidimensional and Jagged Arrays:Jagged ArraysMultidimensional and Jagged Arrays:Jagged Arrays
14. Multi dimensional Arrays 1Multi dimensional Arrays 1
15. Catch OutOfMemoryException
16. Catch IndexOutOfRangeException Exception
w_w___w.__j_a___v__a__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.