Answers for "push in array in c#"

C#
13

c# add to array

var Freds = new [] { "Fred", "Freddy" };
Freds = Freds.Concat(new [] { "Frederick" }).ToArray();
Posted by: Guest on May-01-2020
0

push c# array

for (int i = 0; i < myArray.Length; i++)
{
   if(myArray[i] == null)
   {
       myArray[i] = newValue;
       break;
   }
}
Posted by: Guest on October-30-2021

C# Answers by Framework

Browse Popular Code Answers by Language