Misleading comment in example in chapter 4
arnimarj opened this issue · comments
Árni Már Jónsson commented
Hi, and thanks for an excellent book.
While reading chapter 4 I believe there's a misleading comment:
for (int i = 0; auto x : {'A', 'B', 'C'})
std::cout << i++ << ":" << x << " "; // print: 1:A 2:B 3:C
The incrementor starts at 0
, not 1
as the comment indicates