Pergunta de entrevista da empresa MathWorks

Friend Function in C++ and follow up question about constructor in friend function