0
点赞
收藏
分享

微信扫一扫

第一个代码

Aliven888 2022-02-07 阅读 94
#include<stdio.h>
int main()
{
printf("hello,world!");
return 0;
}

定义变量

类型 变量名 = 0;

类型 变量名; //法律允许但是不推荐

scanf函数

scanf("%d %d",&a,&b);

#include<stdio.h>
int main()
{
int a = 0;
int b = 0;
int sum = 0;
scanf("%d %d",
sum = a + b;
printf("%d",sum);
return 0;
}

sizeof函数

#include<stdio.h>
int main()
{
printf("%d",sizeof(char));
return 0;
}
举报

相关推荐

0 条评论