In C#, what would the output of this program be?
using System;
class DeclareArraysSample {
public static void Main() {
byte[][] s = new byte[3][];
for (int i = 0; i < s.Length; i++) {
s[i] = new byte[i+4];
}
for (int i = 0; i < s.Length; i++) {
Console.Write("{0} - {1} ", i, s[i].Length);
}
}
}
Comments
Leave a comment