From 0ef0dd193a896bddae8ef51e05f2fd7031ba52ae Mon Sep 17 00:00:00 2001 From: AntTAKEOVER Date: Thu, 8 Nov 2018 13:59:39 +0530 Subject: [PATCH] Added visualization of indexes in array. (#22449) The table provides a visual representation of the array, allowing learners to gain a better understanding of indexes in arrays. --- guide/english/csharp/array/index.md | 28 ++++++++++++++++++++++++++++ 1 file changed, 28 insertions(+) diff --git a/guide/english/csharp/array/index.md b/guide/english/csharp/array/index.md index 5d0d17f8b9..d020bc6271 100644 --- a/guide/english/csharp/array/index.md +++ b/guide/english/csharp/array/index.md @@ -40,6 +40,34 @@ You can assign multiple values at once while declaring the array using the forma The above code will assign the value of 5 into element [0], 17 into element [1], 19 into element [2] and 92 into element [3]. + + + + + + + + + + + + + + + + + + + + + + + + + + +
PositionElement
[0]5
[1]17
[2]19
[3]92
+ You can declare, initilise and assign values in the array all at once by using the format below: `dataType [] nameOfArray = new nameOfArray[numberOfElements] {value1,value2,value3,value4};`