Using Table 4.12 (p. 166), parenthesize the following expressions to indicate the order in which the operands are grouped
belongs to book: C++ Primer|Stanley B.Lippman, Josee Lajoie, Barbara E.Moo|5th Edition| Chapter number:4| Question number:4.2
All Answers
total answers (1)
(a) `* vec.begin() ==> * ((vec.begin)())`
The order is: member selector, function call, dereference.
(b) `* vec.begin() + 1 ==> ( * ((vec.begin)())) + 1`
The order is: member selector, function call, dereference, add.
need an explanation for this answer? contact us directly to get an explanation for this answer