Program to find volume of cube, cylinder and rectangle


#include <iostream.h>
#include <conio.h>

//Declaration (Prototypes)
int volume (int);
double volume (double, int) ;
long volume (long, int, int) ;

int main( )
{
    cout << volume (10) <<endl;
    cout <<volume (2.5, 8) <<endl;
    cout <<volume (100L, 75, 15) <<endl;
    getch( );
    return 0;
}
int volume (int x)                 // volume of cube
{
           return (x*x*x);
}
double volume(double r, int h)              // volume of cylinder
{
           return (3.14519*r*r*h) ;
}
long volume(long l, int b, int h)           // volume of rectangular
{
           return (l*b*h);
}

2 comments:

Anonymous said...

Everything is very open with a very clear description of the issues.

It was really informative. Your website is extremely helpful.
Thanks for sharing!

My web blog: natural cellulite treatment

Anonymous said...

check here Louis Vuitton replica Bags hop over to this site click this site click to find out more browse this site

Post a Comment

 
 
 
 


Copyright © 2012 http://codeprecisely.blogspot.com. All rights reserved |Term of Use and Policies|