NO.42打印数组中字母
本帖最后由 我爱橙 于 2022-2-26 14:19 编辑#include <stdio.h>
#include <math.h>
int main()
{
char a[]="This is a program";
printf("%.5s\n", a);
return 0;
}
A.打印This
#include <stdio.h>
#include <math.h>
int main()
{
char a[]="This is a program";
puts(a);
return 0;
}
B.打印This is a program
#include <stdio.h>
#include <math.h>
int main()
{
char a[]="This is a program";
printf("%s\n", a);
return 0;
}
C.打印This is a program
#include <stdio.h>
#include <math.h>
int main()
{
char a[]="This is a program";
a=0;
puts(a);
return 0;
}
D.打印This is a
页:
[1]