6548 | 2023-12-08 15:02:51 | BakosCsongor | A Négyszögletű Kerek Erdő | cpp17 | Elfogadva 100/100 | 3ms | 4232 KiB |
// NOTE: it is recommended to use this even if you don't understand the following code.
#include <fstream>
#include <iostream>
#include <string>
#include <vector>
using namespace std;
int main() {
// uncomment the two following lines if you want to read/write from files
// ifstream cin("input.txt");
// ofstream cout("output.txt");
int N, A, B;
cin >> N >> A >> B;
if(A == B){
cout << "Tul konnyu!";
return 0;
}
if(A < B){
int x;
x = B - A + 1;
if(x < 5){
cout << "Tul konnyu!";
return 0;
}
else{
cout << x;
return 0;
}
}
else {
int x;
x = (N - A) + B + 1;
if(x < 5){
cout << "Tul konnyu!";
return 0;
}
else{
cout << x;
return 0;
}
}
return 0;
}
Részfeladat | Összpont | Teszt | Verdikt | Idő | Memória | ||
---|---|---|---|---|---|---|---|
subtask1 | 0/0 | ||||||
1 | Elfogadva | 3ms | 2024 KiB | ||||
2 | Elfogadva | 3ms | 2180 KiB | ||||
subtask2 | 40/40 | ||||||
3 | Elfogadva | 3ms | 2320 KiB | ||||
4 | Elfogadva | 3ms | 2560 KiB | ||||
5 | Elfogadva | 3ms | 2776 KiB | ||||
6 | Elfogadva | 3ms | 2936 KiB | ||||
7 | Elfogadva | 3ms | 3112 KiB | ||||
8 | Elfogadva | 3ms | 3228 KiB | ||||
9 | Elfogadva | 3ms | 3196 KiB | ||||
subtask3 | 20/20 | ||||||
10 | Elfogadva | 3ms | 3316 KiB | ||||
11 | Elfogadva | 3ms | 3340 KiB | ||||
12 | Elfogadva | 3ms | 3524 KiB | ||||
13 | Elfogadva | 3ms | 3576 KiB | ||||
14 | Elfogadva | 3ms | 3580 KiB | ||||
subtask4 | 40/40 | ||||||
15 | Elfogadva | 3ms | 3780 KiB | ||||
16 | Elfogadva | 3ms | 3896 KiB | ||||
17 | Elfogadva | 3ms | 3908 KiB | ||||
18 | Elfogadva | 3ms | 4028 KiB | ||||
19 | Elfogadva | 3ms | 4152 KiB | ||||
20 | Elfogadva | 3ms | 4232 KiB | ||||
21 | Elfogadva | 3ms | 4232 KiB |