- 함수포인터 : 말그대로 함수를 가리키는 포인터입니다.
- char *는 문자형포인터로 함수의 인자 및 리턴값, 배열로 지정될 수 있습니다.
- 함수포인터도 마찬가지로 함수의 인자 및 리턴값, 배열로 지정될 수 있습니다.
※ C++ How to Program의 예제를 그대로 불러왔습니다.
#include <iostream>
#include <iomanip>
using std::cout;
using std::cin;
using std::endl;
using std::setw;
void bubble(int [], const int, bool (*) (int, int));
void swap(int * const, int * const);
bool ascending(int, int);
bool descending(int, int);
int main() {
return 0;
}
컴파일러는 런타임에서 결정될 문제는 확실한 정보가 있지 않는 한 모르겠다고 의사표시를 하게 만들어져 있음. (0) | 2008.05.05 |
---|---|
const int* pn과 int* const pn의 차이는? (0) | 2008.05.01 |
동적할당영역? (0) | 2008.05.01 |
return ; (0) | 2008.05.01 |
message passing? (0) | 2008.05.01 |