동적할당된 다중(이중) 포인터를 인자로 함수 호출 #include using namespace std; void set_data(int **a,int x,int y); void get_data(int **a,int x,int y); void main() { int **a=NULL; int x=0; int y=0; coutx; couty; a = new int *[x]; for(int i=0;i 더보기 이중포인터 동적할당?!? #include #include using namespace std; int main(void) { char temp[21]={0}; //이름을 입력받을 변수, 따로 변수를 만든 이유는 이름을 입력받아야 이름 크기만큼 할당 할 수 있으니까; char **stuName=NULL; //이중 포인터로 학생 이름을 저장할 변수 선언 int str_len=0; int stuCnt = 0; //학생 수(물론 학생수는 입력하는 사람의 선택에 따라 그 수가 변경됨 coutstuCnt; stuName = new char* [stuCnt];; //이중 포인터로 학생 이름을 저장할 변수 선언 for(int i=0;i 더보기 이전 1 다음