강의

멘토링

커뮤니티

Inflearn Community Q&A

yumin0208057177's profile image
yumin0208057177

asked

(2026) Pass the Information Processing Engineer Practical Exam in One Week

Functions and Recursive Functions (v2)

23분

Resolved

Written on

·

70

0

23분 배열의 첫번째 요소와 포인터가 가르키는 값은 같다고 하셨는데 왜 출력값이 t 가 아니고 this is string 인가요

c정보처리기사

Answer 3

0

weekendcode님의 프로필 이미지
weekendcode
Instructor

%s의 경우, 시작주소부터 null문자를 만날 때까지 모두 출력합니다. 헤당 예제는 %s입니다.

0

yumin0208057177님의 프로필 이미지
yumin0208057177
Questioner

printf("입력된 문자열: %c\n", str);
일경우에 t 인가요?

weekendcode님의 프로필 이미지
weekendcode
Instructor

글자 하나를 출력하려면 해당 주소의 값을 가져와야합니다. 앞에 별표를 붙이셔야 합니다.

*str로 하셔야합니다.

0

yumin0208057177님의 프로필 이미지
yumin0208057177
Questioner

23분 40초에도 배열의 첫번째를 가르킨다고 하셨는데 이것또한 왜 출력값이 this is string2인지궁금합니다

yumin0208057177's profile image
yumin0208057177

asked

Ask a question