土地资源管理专业,热爱英语和编程
2 人赞同了该文章
#include
#include
void main()
{
printf("Hello world");
getch();
}
#include
#include
void main()
{
printf("My Name is : write your name here");
getch();
}
#include
#include
void main()
{
int num1,num2,sum;
printf("Enter the first Number \n");
scanf("%d",&num1);
printf("Enter the second Number \n");
scanf("%d",&num2);
sum = num1 + num2;
printf("Sum of two numbers is : %d \n",sum);
getch();
}
4.#include
#include
void main()
{
float rad,pi=3.14,area;
printf("Enter the Radius of circle \n");
scanf("%f",&red);
area=pi*rad*rad;
printf("Area of circle is : %f \n",area);
getch();
}
相关示译
2.printt()-> Used for Print output(library fuction for print).
getch()->Used for holding output/screen.
3.%d->Used for integer.
\n->Used for new line.
&->Used for Address of variable.
scanf->Used for taking input from keyboard
(Library fuction for taking input).
printf()->Used for printing output on the scr
赞同 2
添加评论
分享