Answers for "while i am using int function in c one extra output is coming"

0

while i am using int function in c one extra output is coming

#include<stdio.h>
int cir(float r)
{
    float dia,circum,are;
    dia=2*r;
    circum=(2*3.14*r);
    are=(3.14*r*r);
    return printf("The circle has diameter %.2f , circumferrence %.2f and Area  %.2f ",dia,circum,are);
}
int main()
{
    float r;
    printf("Enter the radius of a circle: ");
    scanf("%f",&r);
    printf("%f",cir(r));
    return 0;
}
Posted by: Guest on April-06-2021

Browse Popular Code Answers by Language