2IOM 1 –Guruh talabasi Mallayev Mansurjon
8 –misol : Uchburchakning 3 ta tomoni a,b,c berilgan. Uchburchakka ichki chizilgan aylana radiusi r ni aniqlash dasturini tuzing? R=2s/(a+b+c).
___________________________________
#include
#include
using namespace std;
float RADIUS( float, float, float);
int main()
{float a,b,c;
cout << "Hello world!" << endl;
cout<<"\n a \n b \n c \n ni kiriting"<
cin>>a;
cin>>b;
cin>>c;
cout<<"ICHKI CHIZILGAN AYLANA RADIUSI r="<return 0;
}
float RADIUS(float a,float b,float c)
{
return (2*sqrt(((a+b+c)/2)*(((a+b+c)/2)-a)*(((a+b+c)/2)-b)*(((a+b+c)/2)-c))/(a+b+c));
}
Do'stlaringiz bilan baham: |