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 <bits/stdc++.h>
using namespace std;
double a,b;
int main()
{
cin>>a>>b;
if (a>b) cout<<"a cao hon b";
else if (a<b) cout<<"b cao hon a";
else cout<<"a bang b";
return 0;
}
uses crt;
var a:array[1..10]of integer;
i,n,tb:integer;
begin
clrscr;
for i:=1 to 10 do
begin
write('A[',i,']='); readln(a[i]);
end;
for i:=1 to 10 do
if a[i]>=8 then write(a[i]:4);
tb:=0;
for i:=1 to 10 do
tb:=tb+a[i];
writeln;
writeln('Diem trung binh cua 10 ban la: ',tb:4:2);
readln;
end.
refer
uses crt;
var i: integer;
begin
clrscr;
for i:= 1 to 10 do
begin writeln ( ' O ' ) end;
readln
end.
tham khảo
uses crt;
var i: integer;
begin
clrscr;
for i:= 1 to 10 do
begin writeln ( ' O ' ) end;
readln
end.
uses crt;
var a:int64;
begin
clrscr;
readln(a);
writeln(a*4);
readln;
end.
uses crt;
var cao:array[1..60]of real;
i,n:integer;
max,min:real;
begin
clrscr;
write('Nhap so hoc sinh:'); readln(n);
for i:=1 to n do
begin
write('Chieu cao cua ban thu ',i,'='); readln(cao[i]);
end;
max:=cao[1];
min:=cao[1];
for i:=1 to n do
begin
if max<cao[i] then max:=cao[i];
if min>cao[i] then min:=cao[i];
end;
writeln('Chieu cao thap nhat la: ',min:4:2);
writeln('Chieu cao cao nhat la: ',max:4:2);
readln;
end.
#include<iostream>
using namespace std;
int main() {
int a, b, c, d, e;
cin >> a >> b >> c >> d >> e;
int g = a + b + c + d + e;
cout << g / 5;
return 0;
}
tham khảo
uses crt;
var cao:array[1..60]of real;
i,n:integer;
max,min:real;
begin
clrscr;
write('Nhap so hoc sinh:'); readln(n);
for i:=1 to n do
begin
write('Chieu cao cua ban thu ',i,'='); readln(cao[i]);
end;
max:=cao[1];
min:=cao[1];
for i:=1 to n do
begin
if max<cao[i] then max:=cao[i];
if min>cao[i] then min:=cao[i];
end;
writeln('Chieu cao thap nhat la: ',min:4:2);
writeln('Chieu cao cao nhat la: ',max:4:2);
readln;
end.
Tham khảo
uses crt;
var cao:array[1..60]of real;
i,n:integer;
max,min:real;
begin
clrscr;
write('Nhap so hoc sinh:'); readln(n);
for i:=1 to n do
begin
write('Chieu cao cua ban thu ',i,'='); readln(cao[i]);
end;
max:=cao[1];
min:=cao[1];
for i:=1 to n do
begin
if max<cao[i] then max:=cao[i];
if min>cao[i] then min:=cao[i];
end;
writeln('Chieu cao thap nhat la: ',min:4:2);
writeln('Chieu cao cao nhat la: ',max:4:2);
readln;
end.
var x,n:longint;
begin
read(x,n);
while n<>0 do
begin
n:=n-1;
x:=x*x;
end;
write('gia tri ',x,'mu',n,'la : ',x);
end.
hứa 5 sao nhe :)
sorry up nhầm bài
Bài đúng nè
var n,x,x2:longint;
begin
read(x,n);
x2:=x;
n:=n-1; {vì x mũ 1 nên n=n-1}
while n<>0 do
begin
n:=n-1;
x:=x*x2;
end;
write(x,' mu ',n,' = ',x);
end.