QOJ.ac

QOJ

ID题目提交者结果用时内存语言文件大小提交时间测评时间
#142750#6661. 야유회penguinman0 2ms3808kbC++171.1kb2023-08-19 20:04:362023-08-19 20:04:39

Judging History

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

  • [2023-08-19 20:04:39]
  • 评测
  • 测评结果:0
  • 用时:2ms
  • 内存:3808kb
  • [2023-08-19 20:04:36]
  • 提交

answer

#include "workshop.h"

#include <bits/stdc++.h>

using std::cin;
using std::cout;
using std::endl;
using std::string;
using std::vector;
using ll = int;
using vi = vector<ll>;
using vii = vector<vi>;
using pii = std::pair<ll,ll>;

#define rep(i,j,k) for(ll i=ll(j); i<ll(k); i++)
#define REP(i,j,k) for(ll i=ll(j); i<=ll(k); i++)
#define per(i,j,k) for(ll i=ll(j); i>=ll(k); i--)
#define ln "\n"
#define all(a) a.begin(),a.end()
#define pb emplace_back
#define mp std::make_pair
#define mtp std::make_tuple

void init() { }

int f(int x, int y){
    constexpr int LOG = 18;
    rep(i,0,LOG){
        ll a = (x & (1<<i));
        ll b = (y & (1<<i));
        if(a != b){
            int ret = i;
            if(a) ret++;
            return ret;
        }
    }
    return -1;
}

int morning(int my_num, int right_num) {
    return f(my_num, right_num);
}

int afternoon(int left_num, int my_num, int right_num) {
    return f(my_num, right_num);
}

int evening(int left_num, int my_num, int right_num) {
    return f(my_num, right_num);
}

詳細信息

Subtask #1:

score: 0
Wrong Answer

Test #1:

score: 0
Wrong Answer
time: 1ms = 0ms + 1ms
memory: 3792kb,3808kb

input:

2dc2b1d4-8de2-INPUT-bcd3-aa55b691fdb3
1
2
40 40
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39
40 40
0 3 1 5 7 9 6 4 2 10 8 23 21 25 27 29 26 24 22 30 28 13 11 15 17 19 16 14 12 20 18 33 31 35 37 39 36 34 32 38

output:

64be09ab-d709-ERROR-82bc-c23f6124dd26
Wrong Answer [2]

input:

64be09ab-d709-ERROR-82bc-c23f6124dd26
Wrong Answer [2]

output:

64be09ab-d709-ERROR-82bc-c23f6124dd26
Wrong Answer [2]

result:

wrong answer Wrong Answer [2]

Subtask #2:

score: 0
Wrong Answer

Test #8:

score: 0
Wrong Answer
time: 2ms = 1ms + 1ms
memory: 3724kb,3768kb

input:

2dc2b1d4-8de2-INPUT-bcd3-aa55b691fdb3
2
2
40 40
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39
40 40
0 3 1 5 7 9 6 4 2 10 8 23 21 25 27 29 26 24 22 30 28 13 11 15 17 19 16 14 12 20 18 33 31 35 37 39 36 34 32 38

output:

64be09ab-d709-ERROR-82bc-c23f6124dd26
Wrong Answer [2]

input:

64be09ab-d709-ERROR-82bc-c23f6124dd26
Wrong Answer [2]

output:

64be09ab-d709-ERROR-82bc-c23f6124dd26
Wrong Answer [2]

result:

wrong answer Wrong Answer [2]