QOJ.ac

QOJ

ID题目提交者结果用时内存语言文件大小提交时间测评时间
#416751#5255. Greedy Drawersgalen_colin#WA 1ms3588kbC++171.1kb2024-05-22 06:09:452024-05-22 06:09:46

Judging History

你现在查看的是最新测评结果

  • [2024-05-22 06:09:46]
  • 评测
  • 测评结果:WA
  • 用时:1ms
  • 内存:3588kb
  • [2024-05-22 06:09:45]
  • 提交

answer

#include <bits/stdc++.h>

#define fastio ios_base::sync_with_stdio(0); cin.tie(0);
#define int long long

using namespace std;

mt19937 rng(12334);

signed main(){
    fastio
    int n;
    cin >> n;
    vector<pair<int,int>> notebook = {{3,5}, {4,5}, {5,5}, {7,3}, {10,1}, {11,1}, {12,1}};
    vector<pair<int,int>> drawer = {{5,6},{6,6},{8,6},{13,4},{13,2},{14,2},{15,2}};

    int sz = 49;
    set<pair<int,int>> st;

    st.insert({49,49});
    while(st.size() <= n/7){
        int x = rng()%sz+1;
        int y = rng()%sz+1;
        st.insert({x,y});
    }

    for(auto [x,y] : st){
        for(auto [a,b] : notebook){
            cout << x*20 + a << " " << y*20 + b << "\n";
        }
    }

    for(int i = 0; i <= n%7; i++){
        cout << 1000 << " " << 1000-i << "\n";
    }

    cout << "\n";

    for(auto [x,y] : st){
        for(auto [a,b] : drawer){
            cout << x*20 + a << " " << y*20 + b << "\n";
        }
    }

    for(int i = 0; i <= n%7; i++){
        cout << 1000 << " " << 1000-i << "\n";
    }

} 

详细

Test #1:

score: 0
Wrong Answer
time: 1ms
memory: 3588kb

input:

150

output:

43 485
44 485
45 485
47 483
50 481
51 481
52 481
203 305
204 305
205 305
207 303
210 301
211 301
212 301
223 505
224 505
225 505
227 503
230 501
231 501
232 501
363 785
364 785
365 785
367 783
370 781
371 781
372 781
443 265
444 265
445 265
447 263
450 261
451 261
452 261
463 245
464 245
465 245
467...

result:

wrong output format Extra information in the output file