pezy / CppPrimer

:books: Solutions for C++ Primer 5th exercises.
http://dwz.cn/cp5answer
Creative Commons Zero v1.0 Universal
3.29k stars 1.44k forks source link

ex16.6 begin()和end() #107

Closed LukaMod closed 6 years ago

LukaMod commented 7 years ago

16 这个好像不对额 返回类型是T 但arr是const T

pezy commented 7 years ago

这里多余的应该是 const,应该是: T* begin(T(&arr)[size]) 比较合理。在 https://github.com/pezy/CppPrimer/blob/master/ch16/ex16_06_begin_end.h 中已修复。

pezy commented 7 years ago

95