C语言学习(6)

//字符串数组
#include <stdio.h>
int main(){
	char s1[]={"I am a boy"};
	char s2[]={"I am a boy\0 and a student"};//遇到\0字符串结束
	printf("%s\n",s1);
	printf("%s\n",s2);
	return 0;
}

 

猜你喜欢

转载自www.cnblogs.com/Tobi/p/9219827.html