Monday, November 1, 2021

TO FIND VOLUME OF CUBE USING C-PROGRAMING

// Online C compiler to run C program online

#include <stdio.h>

//stdio means standerd inuput and output library it stres printf i.e output and scanf i.e input//

int main() //Decleration// 

{

    int l,b,h, volume;//initilization//

    printf("Enter the value of l\n");

    scanf("%d",&l); // in this line %d is format specifire amd &l is addres //

    printf("Enter the value of b\n");

    scanf("%d",&b);

    printf("Enter the value of h\n");

    scanf("%d",&h);

    volume = l*b*h;

    printf("volume is equal to %d",volume);

    return 0;

}

No comments:

Post a Comment

A Day in the Life of a Computer Science Student

  💻 A Day in the Life of a Computer Science Student Being a computer science student is often misunderstood. People assume we just sit ...