Examveda

What is the correct way to initialize an array of integers with values {1, 2, 3} in C#?

A. int[] numbers = new int[] {1, 2, 3};

B. int numbers[] = {1, 2, 3};

C. int[] numbers = {1, 2, 3};

D. numbers[] = {1, 2, 3};

Answer: Option C


Join The Discussion

Related Questions on Arrays and Strings in C Sharp