Язык С++
#include <iostream>
int main() {
double a, b, c, d;
std::cin >> a >> b >> c >> d;
if (a > b && a > c && a > d) {
std::cout << 1;
}
else if (b > a && b > c && c > d) {
std::cout << 2;
else if (c > a && c > b && c > d) {
std::cout << 3;
else {
std::cout << 4;
return 0;
Copyright © 2024 SCHOLAR.TIPS - All rights reserved.
Answers & Comments
Язык С++
#include <iostream>
int main() {
double a, b, c, d;
std::cin >> a >> b >> c >> d;
if (a > b && a > c && a > d) {
std::cout << 1;
}
else if (b > a && b > c && c > d) {
std::cout << 2;
}
else if (c > a && c > b && c > d) {
std::cout << 3;
}
else {
std::cout << 4;
}
return 0;
}