c语言 7-9

创建一个程序,输入一个实数作为面积,求面积为该实数的正方形的边长。

#include <stdio.h>
#include <math.h>

int main(void)
{
    double area;
    puts("please input the area.");
    printf("area = "); scanf("%lf", &area);
    
    printf("the length of the sige: %f.
", sqrt(area));
    return 0;
}

 

原文地址:https://www.cnblogs.com/liujiaxin2018/p/14789136.html