Untitled
unknown
plain_text
a year ago
387 B
2
Indexable
Never
#include <stdio.h> #include <stdlib.h> #include <math.h> int main() { float a; printf("pls enter the edge of the square:"); scanf("%f", &a); if (a<=0){ printf(" the edge must be a positive number!"); } else { printf(" the perimeter of the square is %f\n", a*4); printf(" the are of the square is %f\n", a*a); } return 0; }