when does a function have to return a reference in c++
Asked 2013-08-05T17:45:10.880
8
In c++, under what scenarios do we have to return a reference from a function? I understand using references as function inputs, but for function outputs, why cannot we only return values or pointers?