일 | 월 | 화 | 수 | 목 | 금 | 토 |
---|---|---|---|---|---|---|
1 | ||||||
2 | 3 | 4 | 5 | 6 | 7 | 8 |
9 | 10 | 11 | 12 | 13 | 14 | 15 |
16 | 17 | 18 | 19 | 20 | 21 | 22 |
23 | 24 | 25 | 26 | 27 | 28 | 29 |
30 | 31 |
Tags
- #3차원배열
- #binary
- html5 new tag
- html youtube
- html id
- #C++ has~a
- #성적관리프로그램
- #자바상속#자바이즈어#is~a
- 토큰경제
- relative path
- 하이퍼레저패브릭
- #다차원포인터
- border-box
- #android activity
- hyperledger transaction
- html charset
- mac terminal command
- #C++ 연산자함수오버로딩
- html object
- html code
- html plug-in
- html multimedia
- git flow
- #CallByAddress
- #bubbleSort
- #1차원배열
- html video
- docker example
- #2차원배열
- #JAVASCRIPT
Archives
- Today
- Total
목록C++ operator function (1)
A sentimental robot
Operator function
연산자 함수 멤버함수와 외부함수로 만들 수 있다. 멤버함수로 만드는 것을 원칙으로 한다. 멤버함수로 만들 수 없는 경우 외부함수로 만들되 멤버함수처럼 접근할 수 있는 friend로 제공한다. 새로운 연산자 함수를 만들지 않는다; 연산자 본연의 의미를 바꾸어서는 안된다. 객체와 객체 , 객체와 데이터를 연산처리 할 수 있게 한다! 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 #include using namespace std; class A { int a; public : A(int num):a(num){} void setA(int a) { this->a..
C++
2018. 9. 19. 13:58