#include<stdio.h>
void main()
{
float a;
printf("Input the value:");
scanf("%f",&a);
if(a>0)
printf("area=%f\n", a*a);
}
if statement: If the side is less than or equal to 0, no calculation; otherwise, calculate the area of a square
Guess you like
Origin www.cnblogs.com/zhangdemingQ/p/12050890.html
Recommended
Ranking