- 1
write a function that can calculate area of a triangle
3 Respuestas
0
you are asking one question twice
...
0
Void area( )
{
int area,b,h;
cout<<"enter the length of the base of the triangle";
cin>>b;
cout<<"enter the length of the height of the triangle";
cin>>h;
area=0.5*b*h;
cout<<"area of triangle"<<area;
}
0
@yash anand....there is one problem...take float instead of int if you wanna use 0.5