public static void ArrayPush<T>(ref T[] table, object value)
Array.Resize(ref table, table.Length + 1);
table.SetValue(value, table.Length - 1);
public static void MergeArrays<T>(ref T[] tableOne, T[] tableTwo) {
foreach(var element in tableTwo) {
ArrayPush(ref tableOne, element);
public static void Main()
string[] words = { "hi", "cool", "hello" };
string[] someWords = { "kill", "him", "lol" };
MergeArrays(ref words, someWords);
Array.ForEach(words, e => Console.WriteLine(e));