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 m,n,s,i:integer;
begin
clrscr;
readln(m,n);
s:=0;
for i:=m to n do
if i mod 2=0 then s:=s+i;
writeln(s);
readln;
end.
uses crt;
var m,n,s,i:integer;
begin
clrscr;
readln(m,n);
s:=0;
for i:=m to n do
if i mod 2=0 then s:=s+i;
writeln(s);
readln;
end.
uses crt;
var a,b,c,p,s:real;
begin
clrscr;
repeat
write('Nhap a='); readln(a);
write('Nhap b=');c readln(b);
write('Nhap c='); readln(c);
until (a>0) and (b>0) and (c>0);
if (a+b>c) and (a+c>b) and (b+c>a) then
begin
kt:=0;
if sqr(a)=sqr(b)+sqr(c) then kt:=1;
if sqr(b)=sqr(a)+sqr(c) then kt:=1;
if sqr(c)=sqr(a)+sqr(b) then kt:=1;
if kt=0 then writeln('Day khong la tam giac vuong')
else begin
writeln('Day la ba canh trong mot tam giac vuong');
p:=(a+b+c)/2;
s:=sqrt(p*(p-a)*(p-b)*(p-c));
writeln('Dien tich tam giac vuong la: ',s:4:2);
end;
end
else writeln('Day khong la ba canh trong mot tam giac');
readln;
end.
#include <bits/stdc++.h>
using namespace std;
double a,b;
int main()
{
cin>>a>>b;
cout<<fixed<<setprecision(2)<<a+b<<endl;
cout<<fixed<<setprecision(2)<<a-b<<endl;
cout<<fixed<<setprecision(2)<<a*b<<endl;
cout<<fixed<<setprecision(2)<<a/b;
return 0;
}