这是什么问题
这是什么问题 求解答 int main(int argc, const char *argv[])你写错了,如果不熟悉,就不要放参数! 傻眼貓咪 发表于 2021-12-21 15:51
int main(int argc, const char *argv[])
你写错了,如果不熟悉,就不要放参数!
改了 不放参数还是不对啊{:10_266:} 还是不能就表示 int main(int argc, char const *argv[]) 没有错,错可能是你的结构类型 .day = ? 我用gcc试了一下你的代码,没有问题#include <stdio.h>
struct date{
int month, day, year;
};
int main(int argc, char const *argv[]){
struct date today = {12, 21, 2021};
struct date thismonth = {.month = 12, .year = 2021};
printf("xxxxx %i %i %i\n", today.year, today.month, today.day);
printf("xxxx %i %i %i", thismonth.year, thismonth.month, thismonth.day);
return 0;
} 傻眼貓咪 发表于 2021-12-21 16:24
我用gcc试了一下你的代码,没有问题
是dev c++的问题吗我用dev c++编译不行 LeaflLit 发表于 2021-12-21 21:03
是dev c++的问题吗我用dev c++编译不行
能支持 C99 吗? 傻眼貓咪 发表于 2021-12-21 21:07
能支持 C99 吗?
刚下了dev c++ 6.3 程序可以了{:10_247:} LeaflLit 发表于 2021-12-21 21:24
刚下了dev c++ 6.3 程序可以了
感谢{:10_254:} LeaflLit 发表于 2021-12-21 21:25
感谢
{:10_254:}
页:
[1]