Guruh talabasi Komiljonov Aslidin hemisda 4- raqam Topshiriq
Download 129.65 Kb. Pdf ko'rish
|
deadline
622-22 guruh talabasi Komiljonov Aslidin HEMISDA 4- raqam Topshiriq Аsоsi uchburchаkdаn ibоrаt bo’lgаn pirаmidаni ifоdаlоvchi klаss yarаting. #include #include using namespace std; class qwerty { public: int tomon; int apofema; int balandlik; int yuza(){ return tomon*sqrt(3)*(tomon+sqrt(pow(tomon,2)+12*pow(balandlik,2))); } float hajm() { return pow(tomon,2)*sqrt(3)*(12*pow(apofema,2)-pow(tomon,2))/12; } }; int main() { int f,h,a; qwerty shakl1; cout<<"\n\t\t:::MUNTAZAM UCHBURCHAKLI:::"; cout<<"\n\t\t :::PIRAMIDA:::"; cout << "\n\t apofemasini kiriting f= ";cin >> f; cout << "\n\t asos balandligini kiriting h= ";cin >> h; cout << "\n\t tomonini kiriting a= ";cin >> a; shakl1.apofema = f; shakl1.balandlik = h; shakl1.tomon = a; cout << "\n\n\t\t\tTo'la sirti S= " << shakl1.yuza() ; cout << "\n\t\t\tHajmi V= " << shakl1.hajm() << endl; return 0; } Download 129.65 Kb. Do'stlaringiz bilan baham: |
Ma'lumotlar bazasi mualliflik huquqi bilan himoyalangan ©fayllar.org 2024
ma'muriyatiga murojaat qiling
ma'muriyatiga murojaat qiling