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.
Program HOC24;
var Toan,Ly,Tin,TBMToan,TBMLy,TBMTin: real;
i,n: byte;
begin
write('Nhap so ban hoc sinh trong lop: '); readln(n);
for i:=1 to n do
begin
write('Nhap diem Toan; Ly; Tin cua ban thu ',i,': ');
readln(Toan[i],Ly[i],Tin[i]);
end;
TBMToan:=0; TBMLy:=0; TBMTin:=0;
For i:=1 to n do
begin
TBMToan:=TBMToan+Toan[i];
TBMLy:=TBMLy+Ly[i];
TBMTin:=TBMTin+Tin[i];
end;
writeln('Diem trung binh mon Toan la: ',TBMToan:5:1);
writeln('Diem trung binh mon Ly la: ',TBMLy:5:1);
writeln('Diem trung binh mon Tin la: ',TBMTin:5:1);
For i:=1 to n do
writeln('Diem trung binh 3 mon cua ban thu ',i,' la: ',TBMToan+TBMLy+TBMTin:5:1);
Readln
end.
uses crt;
var toan,ly,hoa,van,anh,dtb:real;
begin
clrscr;
write('Nhap diem Toan:'); readln(toan);
write('Nhap diem Ly:'); readln(ly);
write('Nhap diem Hoa:'); readln(hoa);
write('Nhap diem Van:'); readln(van);
write('Nhap diem Anh:'); readln(anh);
dtb:=(toan+ly+hoa+van+anh)/5;
if dtb>=8 then writeln('Gioi');
if (6,5<=dtb) and (dtb<8) then writeln('Kha');
if (5<=dtb) and (dtb<6,5) then writeln('Trung binh');
if dtb<5 then writeln('Yeu');
readln;
end.
program TinhTBCMon;
var
n, i: integer;
diemAnh, diemVL, tongDiemAnh, tongDiemVL: real;
begin
tongDiemAnh := 0;
tongDiemVL := 0;
write('Nhap so hoc sinh: ');
readln(n);
for i := 1 to n do
begin
write('Nhap diem Tieng Anh cua hoc sinh ', i, ': ');
readln(diemAnh);
tongDiemAnh := tongDiemAnh + diemAnh;
write('Nhap diem Vat ly cua hoc sinh ', i, ': ');
readln(diemVL);
tongDiemVL := tongDiemVL + diemVL;
end;
writeln('Diem trung binh mon Tieng Anh cua lop la: ', tongDiemAnh/n:0:2);
writeln('Diem trung binh mon Vat ly cua lop la: ', tongDiemVL/n:0:2);
readln;
end.
program DiemTB;
var
diemToan, diemVan, diemTB: real;
begin
write('Nhap diem mon Toan: ');
readln(diemToan);
write('Nhap diem mon Van: ');
readln(diemVan);
diemTB := (diemToan + diemVan) / 2;
writeln('Diem trung binh: ', diemTB:0:2);
if diemTB >= 5 then
writeln('Chuc mung! Ban da dau ky thi.')
else
writeln('Rat tiec! Ban da truot ky thi.');
readln;
end.
#include <bits/stdc++.h>
using namespace std;
double a,b,c,tb;
int main()
{
cin>>a>>b>>c;
tb=((a+b)*2+c)/5;
if (tb>=9) cout<<"Gioi";
else if ((tb>=7) and (tb<9)) cout<<"Kha";
else if ((tb>=5) and (tb<7)) cout<<"Trung binh";
else cout<<"Yeu";
return 0;
}
#include <bits/stdc++.h>
using namespace std;
double a,b,c,tb;
int main()
{
cin>>a>>b>>c;
tb=((a+b)*2+c)/5;
if (tb>=9) cout<<"Gioi";
else if ((tb>=7) and (tb<9)) cout<<"Kha";
else if ((tb>=5) and (tb<7)) cout<<"Trung binh";
else cout<<"Yeu";
return 0;
}