Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...


How to transpose rows into columns and columns into rows in
a multi-dimensional array ?



How to transpose rows into columns and columns into rows in a multi-dimensional array ?..

Answer / kalpana

int [,]array=new int[2,2] {{1,2},{3,4}};

transpose of the array is

for(int i=0;i<2;i++)
{
for(int j=0;j<2;j++)
{
Console.Write("{0} ",a[j,i]);
}
}

o/p : 1 3
2 4

Is This Answer Correct ?    1 Yes 1 No

Post New Answer

More ASP.NET Interview Questions

I have to send data throug querystring from one page to another. But it should not be displayed in URL. How it is possible?

6 Answers   EMR, Wipro,


What does asp in asp.net stand for?

0 Answers  


What is Hidden Fields in Asp.Net

4 Answers  


Explain how is the asp.net mvc architecture different from others? : asp.net mvc

0 Answers  


How would you get ASP.NET running in Apache web servers - why would you even do this?

1 Answers   Siebel Systems,


Can One website be made using two different languages like c#,vb.net etc......

4 Answers   ABC,


Give me one example of Web API Routing?

0 Answers  


What are Caching techniques in .NET

0 Answers   Microsoft,


State differences between MVC and WebAPI

0 Answers  


what is the auto option in XML ?

1 Answers  


what is clr .

1 Answers   Patni,


How does the regular expression validator work? What are two situations when you might want to use one?

2 Answers  


Categories