
6 May
2015
6 May
'15
12:43 a.m.
David Stone wrote:
The one main design decision for a multi-dimensional array is what begin() and end() iterate over: int, or array
?
They iterate over int[4][5] in my suggestion. This is, admittedly, not a "true" multidimensional array, it's just how C arrays work. int a[3][4][5]; for( auto& x: a ) { // x is int (&)[4][5] here } This is consistent with begin() returning T* == int(*)[4][5] and op[] returning T& == int(&)[4][5].