Hãy nhập câu hỏi của bạn vào đây, nếu là tài khoản VIP, bạn sẽ được ưu tiên trả lời.
uses crt;
var r,cd,cr,s,p: real;
begin
clrscr;
write('Nhap ban kinh: '); readln(r);
cd:=r*2*3.14;
cr:=1/3*cd;
s:=cd*cr;
p:=(cd+cr)*2;
writeln('Dien tich la: ',s);
writeln('Chu vi la: ',p);
readln;
end.
program chuvi_dientich_hinhtron;
uses crt;
const pi = 3.14;
var R: integer;
cv, dt: real;
begin
clrscr;
writeln; { xuong dong }
readln ( R );
cv:= 2*R*pi;
writeln ( ' chu vi = ' , cv : 8:2 );
dt:=R*R*pi;
writeln ( 'dien tich = ', dt :8:2 );
readln;
end.
Chúc bạn học tốt
program TinhChuViVaDienTichHinhTron;
const
pi: real = 34.4;
var r, chuVi, dienTich: real;
begin
write('Nhap ban kinh cua hinh tron: ');
readln(r);
chuvi := 2 * pi * r;
dientich := pi * sqr(r);
writeln('Chu vi cua hinh tron la: ', chuvi:0:1);
writeln('Dien tich cua hinh tron la: ', dientich:0:1);
end.
Câu 2:
#include <bits/stdc++.h>
using namespace std;
double a,b,cv,dt;
int main()
{
cin>>a>>b;
cv=(a+b)*2;
dt=a*b;
cout<<"Chu vi la:"<<fixed<<setprecision(2)<<cv<<endl;
cout<<"Dien tich la:"<<fixed<<setprecision(2)<<dt;
return 0;
}
Program hoc24;
Uses crt;
Var r,S,C:real;
Begin
Write ('Ban kinh la');
Readln (r);
S:=r*r*3.14;
C:=r*2*3.14;
Writeln ('Chu vi la',C);
Writeln ('Dien tich la',S);
Readln;
End.
b.
Program Hoc24;
Uses crt;
Var r,S,C:real;
Begin
Write ('Ban kinh la');
Readln (r);
S:=r*r*3.14;
C:=r*2*3.14;
Writeln ('Chu vi la',C);
Writeln ('Dien tich la',S);
Readln;
End.
#include <bits/stdc++.h>
using namespace std;
double a;
int main()
{
cin>>a;
cout<<"Chu vi la:"<<fixed<<setprecision(2)<<a*2*pi<<endl;
cout<<"Dien tich la:"<<fixed<<setprecsion(2)<<a*a*pi;
return 0;
}