#define _CRT_SECURE_NO_WARNINGS 1
#include<stdio.h>
int main()
{
char arr1[] = "abc";
char arr2[] = { 'a', 'b', 'c','\0' };//一段数组的结束标志是\0
printf("%d\n", strlen(arr1));
printf("%d\n", strlen(arr2));
return 0;
}
//对数组的学习,对数组长度的打印
2023-12-04 09:23:04
#define _CRT_SECURE_NO_WARNINGS 1
#include<stdio.h>
int main()
{
char arr1[] = "abc";
char arr2[] = { 'a', 'b', 'c','\0' };//一段数组的结束标志是\0
printf("%d\n", strlen(arr1));
printf("%d\n", strlen(arr2));
return 0;
}
//对数组的学习,对数组长度的打印