
10-12-2009, 11:15 PM
|
 | Toddler | |
Join Date: Oct 2007 Location: Mumtaaz Abad Multan Age: 22
Posts: 22
Thanks: 1
Thanked 10 Times in 8 Posts
Class Roll Number: 07-06 Time Spent Online: 13 Hours 20 Minutes 51 Seconds | |
Taking transpose of a matrix program code: implementation of 2 dimensional arrays Taking Transpose of a Matrix |  | | | Module Mattranspose Sub Main() Dim i, j As Integer Dim Matrix1 As Integer(,) = New Integer(,) {{1, 2, 3}, {4, 5, 6}} For i = 0 To 1 For j = 0 To 2 Console.Write(Matrix1(i, j) & vbTab) Next Console.Write(vbCrLf) Next Console.Write("Transpose of the above matrix is given below:" & vbCrLf) For i = 0 To 2 For j = 0 To 1 Console.Write(Matrix1(j, i) & vbTab) Next Console.Write(vbCrLf) Next End Sub End Module | | |  | | |
Last edited by .BZU.; 10-12-2009 at 11:16 PM.
Reason: code tag removed from heading...
|