Points:
100 (p)
Time limit:
1.0s
Memory limit:
256M
Input:
stdin
Output:
stdout
Viết chương trình nhập vào ba số nguyên \(a, b, c\). In ra số lớn nhất của 3 số đó.
Input
- Ba số nguyên \(a,b,c\) mỗi số trên 1 dòng.
Output
- Một số nguyên là giá trị lớn nhất của 3 số.
Example
Test 1
Input
2
6
3
Output
6
Test 2
Input
-243
-543
-123
Output
-123
Comments
giới hạn là bao nhiêu ạ, để biết dùng int hay long long 🙂
include<bits/stdc++.h>
using namespace std;
int main()
{
long long a, b, c;
cin >> a >> b >> c;
cout << max({a,b,c});
return 0;
}
Var a,b,c:int64;
function max(k,n,c:int64):int64;
begin
If (a>b) and (a>c) then max:=a else if (b>a) and (b>c) then max:=b else if (c>a) and (c>b) then max:=c else If(a=c) and (a>b) then max:=a;
end;
begin
readln(a,b,c);
Writeln(max(a,b,c));
readln
end.
matday
A
a = int(input())
b = int(input())
c = int(input())
print(max(a,b,c))
Thế này là sao vậy admin???

ok
This comment is hidden due to too much negative feedback. Click here to view it.
This comment is hidden due to too much negative feedback. Click here to view it.
3 more comments