QOJ.ac

QOJ

IDProblemSubmitterResultTimeMemoryLanguageFile sizeSubmit timeJudge time
#375576#5531. ICCsichengzhou0 52ms4316kbC++141.5kb2024-04-03 13:25:032024-07-01 04:28:43

Judging History

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

  • [2024-07-01 04:28:43]
  • 管理员手动重测本题所有提交记录
  • 测评结果:0
  • 用时:52ms
  • 内存:4316kb
  • [2024-04-03 13:25:03]
  • 评测
  • 测评结果:0
  • 用时:53ms
  • 内存:4204kb
  • [2024-04-03 13:25:03]
  • 提交

answer

#include "icc.h"
#include<bits/stdc++.h>
using namespace std;
const int N=105;
int n;
vector<int>c[N];
int a[N],b[N],lena,lenb;
void run(int n)
{
    for(int i=1;i<=n;i++)
    {
        c[i].clear();
        c[i].push_back(i);
    }
    for(int t=1;t<n;t++)
    {
    for(int j=0;j<=6;j++)
    {
        lena=lenb=0;
        for(int i=1;i<=n;i++)
        {
            for(int k=0;k<c[i].size();k++)
            {
                if(i>>j&1)
                {
                    a[lena++]=c[i][k];
                }else{
                    b[lenb++]=c[i][k];
                }
            }
        }
        if(query(lena,lenb,a,b))
        {
            int la,ra;
            la=0,ra=lena;
            while(la+1<ra)
            {
                int mid=(la+ra)/2;
                if(query(ra-mid,lenb,a+mid,b))
                {
                    la=mid;
                }else{
                    ra=mid;
                }
            }
            lena=1;
            int lb,rb;
            lb=0,rb=lenb;
            while(lb+1<rb)
            {
                int mid=(lb+rb)/2;
                if(query(lena,rb-mid,a+la,b+mid))
                {
                    lb=mid;
                }else{
                    rb=mid;
                }
            }
            setRoad(a[la],b[lb]);
            for(int v=0;v<c[b[lb]].size();v++)
            {
                c[a[la]].push_back(c[b[lb]][v]);
            }
            c[b[lb]].clear();
            break;
        }
    }
    }
}

Details

Tip: Click on the bar to expand more detailed information

Subtask #1:

score: 0
Wrong Answer

Test #1:

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

input:

1
1500 3
15

0
2

0.0
2.5

0
3.5

0

1 1

output:

0
Wrong road!

result:

wrong answer 

Subtask #2:

score: 0
Wrong Answer

Test #3:

score: 0
Wrong Answer
time: 7ms
memory: 4164kb

input:

1
2500 4
50

0
0

0.0
3.5

0
2.5

5

1 1

output:

0
Wrong road!

result:

wrong answer 

Subtask #3:

score: 0
Wrong Answer

Test #6:

score: 0
Wrong Answer
time: 8ms
memory: 4316kb

input:

1
2250 6
100

0.05
2.3

0.1
0.7

0
1.5

1.7

1.1 1

output:

0
Wrong road!

result:

wrong answer 

Subtask #4:

score: 0
Wrong Answer

Test #10:

score: 0
Wrong Answer
time: 6ms
memory: 4200kb

input:

1
2000 5
100

0.01
1.00

0.10
1.70

0.00
1.50

5.0

1.20 1

output:

0
Wrong road!

result:

wrong answer 

Subtask #5:

score: 0
Wrong Answer

Test #14:

score: 0
Wrong Answer
time: 12ms
memory: 4208kb

input:

1
1775 4
100

0.00
0.00

0.00
2.70

0.10
7.55

0.0

1.15 1

output:

0
Wrong road!

result:

wrong answer 

Subtask #6:

score: 0
Wrong Answer

Test #20:

score: 0
Wrong Answer
time: 52ms
memory: 4168kb

input:

1
1625 5
100

0.00
0.00

0.00
3.00

0.00
1.00

0.0

3 1

output:

0
Wrong road!

result:

wrong answer