CPP operator overloading

CPP operator overloading

Creator
Creator
Seonglae ChoSeonglae Cho
Created
Created
2019 Nov 20 6:10
Editor
Edited
Edited
2023 Apr 25 15:50
Refs
+, - 정의 등
<<
comma
4 + - / *
 
 
parameter is const because it should not be changed
return type is const because it is anonymous object. It is not good so recommended
 
 
 
 

- operator is overloaded twice

 
 
 

Can overload as "member operator”

 
 
 
 
 
 

Recommendations