結果 : method vs function c++