#include <stdio.h>
#include <stdlib.h>
#include <string.h>
int main(void)
{
char str[50];
int idx=0;
gets(str);//띄어쓰기까지 포함할수있는 함수 위에 #include <string.h>를 더추가한다
printf("\n%s\n", str);
while(str[idx] != NULL)
{
idx++;
}
printf("%d\n",idx);
system("pause");
return 0;
}
2016.04.02 09:55
띄어쓰기까지 프로그램 출력하기(승민)
조회 수 1946 추천 수 0 댓글 0