I have:
double[,] table = new double[3,4];
How to check both sizes of this table? table.Lengthgives me 12which represents the total number of elements in the table.
table.Length
12
Use the method GetLength.
GetLength
So, table.GetLength(0)3 will return, and table.GetLength(1)4 will return.
table.GetLength(0)
table.GetLength(1)
The parameter for GetLengthis the zero size of the array you want to know.
Table.GetLength(0); gives you 3
Table.GetLength(0);
Table.GetLength(1); gives you 4
Table.GetLength(1);
Hope this helps.
GetLength?
ref
Source: https://habr.com/ru/post/1780645/More articles:How to enable authentication for Mercurial push / pull operation when using TortoiseHg? - dvcsRegular expression to clear XML - xmlHow to create a custom table for a dating site? - phpИспользование script в автоматизированном процессе сборки - powershellиспользование веб-службы с аутентификацией всегда дает сообщение Требуется аутентификация - web-servicesShow software menu programmatically (wp7) - windows-phone-7Is there any way to get event delegate - c #How to embed UIImage in a UIWebView - objective-cprint character list in clojure - lispDoes Twitter support two-way oAuth? - oauthAll Articles