Inflearn brand logo image

Inflearn Community Q&A

taechoon's profile image
taechoon

asked

Learn C Programming by Following Along with Hong Jeong-mo

10.10 const, arrays, and pointers

const

Written on

·

166

1

double arr2[3]={1.0 , 2.0 , 3.0};

const double *pd =arr2;

이라할때 

(1)*pd=1000.0 , arr[0]=1000.0 ; 이 불가능한것이지 

(2)pd[2]= 1024.0, arr[1]=1001.0; 과 같은 수정은 가능하지 않나요?

배열 arr2[3]에 const를 붙여야 (2)도 불가능해지지 않나요? 

c

Answer 1

1

honglab님의 프로필 이미지
honglab
Instructor

질문의 제목에 질문 내용이 요약되어 있어야 합니다.

이런 질문들은 직접 해보시면 쉽게 확인하실 수 있습니다. 안될 경우에도 output창에 설명이 나옵니다.

taechoon's profile image
taechoon

asked

Ask a question