Program Menghitung Jari Dan Luas Lingkaran Dalam Dari Segitiga
Posted by Budi Arieyanto | Posted in Borlant C++ | Posted on 04.52
#include<iostream.h>
#include<conio.h>
#include<math.h>
void main()
{
const float phi=3.141592;
int A,B,C;
float S,R,luas;
clrscr();
cout<<"MENGHITUNG LUAS LINGKARAN DALAM DARI SEGITIGA"<<endl;
A=5;
B=10;
C=15;
S=0.5*(A+B+C);
R=(sqrt(S*(S-A)*(S-B)*(S-C))/S);
luas=phi*R*R;
cout<<"\n\nNilai R = "<<R<<endl;
cout<<"\n\nNilai Luas = "<<luas<<endl;
getche();
}


Comments (0)
Posting Komentar