Files
contests/2023/rcpc/d2/editorial/c-basketball-655.cpp
2024-04-22 16:45:09 +03:00

26 lines
362 B
C++

#include <bits/stdc++.h>
using namespace std;
int main()
{
int n;
cin >> n;
if (n == 1)
{
cout << "No";
return 0;
}
if (n % 3 == 0)
{
cout << 0 << ' ' << n / 3;
}
else if (n % 3 == 1)
{
cout << 2 << ' ' << (n - 4) / 3;
}
else
{
cout << 1 << ' ' << (n - 2) / 3;
}
}