Skip to content

Instantly share code, notes, and snippets.

@palcodes
Created April 11, 2020 06:38
Show Gist options
  • Save palcodes/f4f4ba159ab3db8e92f2710c59479b76 to your computer and use it in GitHub Desktop.
Save palcodes/f4f4ba159ab3db8e92f2710c59479b76 to your computer and use it in GitHub Desktop.
main() {
int size = 10;
var i, j;
List<List<int>> mat = new List<List<int>>(size);
for (i = 0; i < size; i++) {
List<int> list = new List<int>(size);
for (j = 0; j < size; j++) {
list[j] = j;
}
mat[i] = list;
}
print(mat);
print("PRINT AN ELEMENT:");
print(mat[4][2]);
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment