Jagged arrays in C#
- by chupinette
Hello!
Im trying to store to array of ints in a jagged array:
while (dr5.Read())
{
customer_id[i] = int.Parse(dr5["customer_id"].ToString());
i++;
}
dr5 is a datareader. I am storing the customer_id in an array, i also want to store scores in another array.
I want to have something like below within the while loop
int[] customer_id = { 1, 2 };
int[] score = { 3, 4};
int[][] final_array = { customer_id, score };
Can anyone help me please ?