0 bình luận về “Tìm số lớn hơn trong 2 số a,b (a,b số nguyên)”
Program NN; Uses crt; Var a,b: longint; Begin Clrscr; Write(‘Nhap a,b: ‘); Readln(a,b); If a>b then Write(a,’ lon hon’) Else If b>a then Write(b,’ lon hon’) Else Write(‘Bang nhau’); Readln End.
Program NN;
Uses crt;
Var a,b: longint;
Begin
Clrscr;
Write(‘Nhap a,b: ‘); Readln(a,b);
If a>b then Write(a,’ lon hon’)
Else If b>a then Write(b,’ lon hon’)
Else Write(‘Bang nhau’);
Readln
End.
program ctpt;
uses crt;
var a, b: integer;
begin
clrscr;
write(‘Nhap a = ‘); readln(a);
write(‘Nhap b = ‘); readln(b);
if a>b then write(a) else
if a<b then write(b) else
write(a:4,b);
readln
end.