Just FYI - you can write b[0, 7] in Nim too with ease const Rows = 8 Cols = 8 type Row = array[Cols, int] Board = array[Rows, Row] proc `[]`(b: Board, r, c: int): int = b[r][c] var b: Board b[0][7] = 4 echo b[0][7] echo b[0, 7] Run
- What is the elegant way to construct 2D array? leeooox
- What is the elegant way to construct 2D array? Stefan_Salewski
- What is the elegant way to construct 2D array? Yardanico
- What is the elegant way to construct 2D array... Stefan_Salewski