bạn nào giúp mình làm bài này được ko! làm bằng pascal ấy
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.
#include <iostream>
#include <iomanip>
int main() {
int r;
std::cin >> r;
double pi = 3.14;
double perimeter = 2 * pi * r;
double area = pi * r * r;
std::cout << std::fixed << std::setprecision(2);
std::cout << "p= " << perimeter << std::endl;
std::cout << "s= " << area << std::endl;
return 0;
}
#include <iostream>
#include <iomanip>
using namespace std;
int main() {
int r;
const float Pi = 3.14;
cout << "Nhap ban kinh hinh tron: ";
cin >> r;
float chu_vi = 2 * Pi * r;
float dien_tich = Pi * r * r;
cout << fixed << setprecision(2);
cout << "p= " << chu_vi << endl;
cout << "s= " << dien_tich << endl;
return 0;
}
uses crt;
var st,k,t:string;
d,dem,i:integer;
begin
clrscr;
readln(st);
d:=length(st);
k='';
dem=1;
for i:=2 to d do
begin
if st[i]=st[i-1] then inc(dem);
if st[i]<>st[i-1] then
btegin
str(dem,t);
if dem>1 then k:=k+t+st[i-1];
else k:=k+st[i-1];
dem=1;
end;
if (i=d) then
begin
str(dem,t);
if dem>1 then k:=k+t+st[i];
else k:=k+st[i];
end;
end;
write(k);
readln;
end.
uses crt;
var st:string;
d,i,n:integer;
begin
clrscr;
readln(n);
str(n,st);
d:=length(st);
for i:=d downto 1 do
write(st[i]);
readln;
end.
a, b = map(int, input().split())
c = int(input())
result = ((a % c) * (b % c)) % c
print(result)
#include <iostream>
using namespace std;
int main() {
long long a, b, c;
cin >> a >> b >> c;
long long result = ((a % c) + (b % c)) % c;
cout << result << endl;
return 0;
}
#include <iostream>
using namespace std;
int main() {
int x, y;
cin >> x >> y;
int temp = x;
x = y;
y = temp;
cout << "x=" << x << endl;
cout << "y=" << y << endl;
return 0;
}
#include <iostream>
using namespace std;
int main() {
int N,M,X;
cin >> N >> M >> X;
cout << N-M*X;
return 0;
}
var s,n:real;
begin
readln(n);
s:=n*2*10;
write(s:0:0);
readln;
end.