Submission #845308

# Submission time Handle Problem Language Result Execution time Memory
845308 2023-09-06T13:07:19 Z vjudge1 Konstrukcija (COCI20_konstrukcija) C++17
0 / 110
0 ms 600 KB
#pragma GCC optimize("O3,unroll-loops")
#pragma GCC target("avx2,bmi,bmi2,lzcnt,popcnt")
#include <bits/stdc++.h>
using namespace std;
#define int long long
 
#define ONLINE_JUDGE
#ifndef ONLINE_JUDGE
    #define OPEN freopen(".in", "r", stdin); \
                 freopen(".out", "w", stdout);
#else
    #define OPEN void(23);
#endif

void solve()
{
    int k; cin >> k;
    if(k == 1) cout << 1 << " " << 0;
    else if(k == 0)
    {
        cout << 6 << " " << 6 << "\n";
        cout << 1 << " " << 4 << "\n";
        cout << 1 << " " << 5 << "\n";
        cout << 4 << " " << 3 << "\n";
        cout << 5 << " " << 3 << "\n";
        cout << 3 << " " << 2 << "\n";
        cout << 2 << " " << 6 << "\n";
    }
    else
    {
        cout << -k +3 << " " << (-k +1) * 2 << "\n";
        int cnt = 2;
        for(int i = 1; i <= -k +1; i++, cnt++)
            cout << 1 << " " << cnt << "\n" << cnt << " " << -k +3 << "\n";
    }

    return;
}

int32_t main()
{
    OPEN;

    ios_base::sync_with_stdio(false);
    cin.tie(0); cout.tie(0);

    int t = 1; //cin >> t;
    while(t--)
    {
        solve();
    }
}
# Verdict Execution time Memory Grader output
1 Incorrect 0 ms 600 KB Integer parameter [name=N] equals to -394, violates the range [1, 1000]
2 Halted 0 ms 0 KB -
# Verdict Execution time Memory Grader output
1 Incorrect 0 ms 348 KB Wrong answer.
2 Halted 0 ms 0 KB -
# Verdict Execution time Memory Grader output
1 Incorrect 0 ms 600 KB Integer parameter [name=N] equals to -394, violates the range [1, 1000]
2 Halted 0 ms 0 KB -
# Verdict Execution time Memory Grader output
1 Incorrect 0 ms 600 KB Integer parameter [name=N] equals to -394, violates the range [1, 1000]
2 Halted 0 ms 0 KB -