QOJ.ac

QOJ

IDProblemSubmitterResultTimeMemoryLanguageFile sizeSubmit timeJudge time
#943464#4923. 整数sandforce5 1ms6108kbC++266.0kb2025-03-19 21:04:452025-03-19 21:04:45

Judging History

This is the latest submission verdict.

  • [2025-03-19 21:04:45]
  • Judged
  • Verdict: 5
  • Time: 1ms
  • Memory: 6108kb
  • [2025-03-19 21:04:45]
  • Submitted

answer

#include<bits/extc++.h>
#include "integer.h"
//
//#ifndef __GRADER_INTEGER_H_
//#define __GRADER_INTEGER_H_
//#include <vector>
//int operate(const int i);
//std::vector<int> findPermutation(int n);
//#endif
//namespace SampleIntegerGrader
//{
//	int n, p[1 << 21], S[1 << 21];
//	int currentPopcnt, ops;
//	double scoreof(const int s) {
//		if(s < 800000) return 1;
//		if(s <= 2000000) return 800000.0 / s;
//		if(s > 200000000) return 0;
//		return (9 - log10(s * 5)) / 5;
//	}
//	void reportResult(const std::vector<int> &answer) {
//		if((int)answer.size() != n)
//			puts("WA"), (void)printf("Invalid Answer length: expected %d, found %d\n", n, (int)answer.size()), exit(-1);
//		for(int i=0; i<n; i++)
//			if(answer[i] != p[i])
//				puts("WA"), (void)printf("Incorrect answer: p_%d is expected to be %d but found %d\n", i, p[i], answer[i]), exit(-1);
//		puts("OK"), (void)printf("Passed using %d operation(s): scoring %.3lf\n", ops, scoreof(ops));
//	}
//	void quitHalf(const int kth) {
//		puts("WA"), printf("Invalid query: Operation on %d violates range [0,%d]\n", kth, n - 1);
//		exit(-1);
//	}
//	int operate(const int kth) {
//		if(kth < 0 || kth >= n)
//			quitHalf(kth);
//		ops++;
//		S[p[kth]]++, currentPopcnt++;
//		for(int i = p[kth]; S[i] == 2; i++)
//			S[i] = 0, S[i + 1]++, currentPopcnt--;
//		return currentPopcnt;
//	}
//	inline int _debug(int n){
//		for(int i=0;i<n;i++)if(S[i]==1)return 1;
//			return 0;
//	}
//	void main() {
//		scanf("%d", &n);
//		for(int i = 0; i < n; i++) scanf("%d", p + i);
//		auto vans = findPermutation(n);
//		reportResult(vans);
//	}
//}
//int operate(const int kth) {
//	return SampleIntegerGrader::operate(kth);
//}
//int main() {
//	SampleIntegerGrader::main();
//	return 0;
//}
///
/*
69
4 51 11 15 24 35 17 36 26 50 67 39 19 2 47 56 59 18 32 40 5 21 57 12 14 42 27 62 63 58 30 38 13 68 3 54 55 64 9 22 66 23 20 34 1 10 31 0 46 41 65 28 52 43 16 60 49 7 44 25 29 61 6 45 53 48 8 33 37
*/
using namespace std;
using namespace __gnu_pbds;
#define il inline
#define ll long long
#define lll __int128
#define ull unsigned long long
#define ld long double
#define db double
#define gc getchar();
#define pc(x) putchar(x)
#define O(x) cout<<x<<'\n';
#define adde(x,y) emplace_back(make_pair(x,y))

#define pbset(typ) tree< typ ,null_type,std::less< typ >, __gnu_pbds::rb_tree_tag,__gnu_pbds::tree_order_statistics_node_update>
#define pbmap(typ1,typ2) tree< typ1 , typ2 ,std::less< typ1 >, __gnu_pbds::rb_tree_tag,__gnu_pbds::tree_order_statistics_node_update>

namespace constant_warrior {
	template<typename T> inline void fr(T& num) {
		num = 0;
		short sign = 1;
		char ch = std::getchar();
		while (ch < '0' || ch > '9') {
			if (ch == '-')sign = -1;
			ch = std::getchar();
		}
		while (ch >= '0' && ch <= '9')num = num * 10 + ch - '0', ch = getchar();
		num = num * sign;
	}
	template<typename T>inline void fw(T x) {
		if (x < 0)std::putchar('-'), x = -x;
		if (x > 9)fw(x / 10);
		std::putchar(x % 10 + '0');
	}
	template<typename T>inline const T& maxf(const T& a, const T& b) {
		if (a > b)return a;
		return b;
	}
	template<typename T>inline const T& minf(const T& a, const T& b) {
		if (a > b)return b;
		return a;
	}
	template<typename T>inline void swapf(T& a, T& b) {
		a ^= b ^= a ^= b;
	}
	template<typename T, typename... Args> inline void fr(T &x, Args&... args) {
		fr(x);
		fr(args...);
	}
}
using namespace constant_warrior;
const int N = 5015;
vector<int> v;
mt19937 rd(time(0));
bitset<N> can_be_prefix[N];//[i][j]:i的前缀可以为j
vector<int> findPermutation(int n){
	for(int i=0;i<n;i++)v.emplace_back(i);
	int T=30;
	for(int i=0;i<n;i++){
		for(int j=0;j<n;j++){
			if(i==j)continue;
			can_be_prefix[i][j]=1;
		}
	}
	int pos0=0x3f3f3f3f;//是前缀最小值的话ppc变小
	for(int i=0;i<n-1;i++){
		operate(i);
	}
	int ppc=operate(n-1);
	shuffle(v.begin(),v.end(),rd);
	for(int i=0;i<n;i++){
//		cerr<<v[i]<<' ';
		int now=operate(v[i]);
//		cerr<<now<<' '<<ppc<<'\n';
		if(now<=ppc){
			pos0=v[i];
		}
		ppc=now;
	}
//	cerr<<'\n';
	operate(pos0);
	ppc=operate(pos0);
//	cerr<<"P0 " <<pos0<<'\n';
	while(T-->0){
//		cerr<<SampleIntegerGrader::_debug(n)<<'\n';
		shuffle(v.begin(),v.end(),rd);
//		for(auto i:v){
//			
//		}
		for(int i=0;i<n;i++){
			int x=operate(v[i]),y=operate(v[i]);
//			cerr<<v[i]<<' ';
			if(y>x){//前缀被操作过
				for(int j=i+1;j<n;j++){
					can_be_prefix[v[i]][v[j]]=0;
				}
			}
			else{
				for(int j=0;j<i;j++){
					can_be_prefix[v[i]][v[j]]=0;
				}
			}
		}
//		cerr<<'\n';
//		for(int i=0;i<n;i++){
//			operate(i),operate(i);
//		}
		operate(pos0);
		ppc=operate(pos0);
	}
	vector<int> res,ans(n);
//	res[0]=pos0;
//	for(int i=0;i<n;i++){
//		for(int j=0;j<n;j++){
//			cerr<<can_be_prefix[i][j]<<' ';
//		}
//		cerr<<'\n';
//	}
	queue<int> q;
	q.emplace(pos0);
	while(q.size()){
		int x=q.front();q.pop();
		res.emplace_back(x);
		for(int i=0;i<n;i++){
			if(can_be_prefix[i][x])q.emplace(i);
		}
	}
	for(auto i:res)cerr<<i<<" ";
	cerr<<'\n';
	for(int i=0;i<n;i++)ans[res[i]]=i;
	return ans;
}




/*
暴力出奇迹,卡常能AC。
Violent makes miracle,pursuing better constant can AC.
多测不清空,OI见祖宗。
multitesting without clearing,oier meets the LCA.
十年OI一场空,不开LL见祖宗。
Ten years of OI just AFO,no #define int long long sees the LCA.
似是神犇成才处,实为蒟蒻黄泉路。
It is likely to be the Au medal for the big old,but in fact it is the Si medal for me.
黄题有恨无正解,码力不若小学生。
A yellow problem I can't AC,codeforces is not as NB as HNO3(Dilute nitric acid).
今生无奈入OI,来世不做信竞人。
This life I am a Siliy Being in oi,next life I won't f**k the sh*t of infomatics.
你%你赛觉得是我的锅那就是我的锅,
因为%你赛出的题,就像是一个毒瘤晚期患者出的题,
他都已经这样了,你为什么不能顺从他呢?
你总要给人最后一段时间一个好的回忆吧,最后的时光里。
*/

Details

Tip: Click on the bar to expand more detailed information

Subtask #1:

score: 5
Accepted

Test #1:

score: 5
Accepted
time: 0ms
memory: 6104kb

input:

1
0

output:

68F82AC1898AF4BFACDCBB49543233A61773093A
OK
Passed using 124 operation(s): scoring 1.000
1.0000000000

result:

ok Passed using 124 operation(s): scoring 1.000

Test #2:

score: 5
Accepted
time: 0ms
memory: 6104kb

input:

3
0 2 1

output:

68F82AC1898AF4BFACDCBB49543233A61773093A
OK
Passed using 248 operation(s): scoring 1.000
1.0000000000

result:

ok Passed using 248 operation(s): scoring 1.000

Test #3:

score: 5
Accepted
time: 1ms
memory: 5976kb

input:

3
0 2 1

output:

68F82AC1898AF4BFACDCBB49543233A61773093A
OK
Passed using 248 operation(s): scoring 1.000
1.0000000000

result:

ok Passed using 248 operation(s): scoring 1.000

Test #4:

score: 5
Accepted
time: 1ms
memory: 5976kb

input:

10
0 2 8 9 1 5 6 3 4 7

output:

68F82AC1898AF4BFACDCBB49543233A61773093A
OK
Passed using 682 operation(s): scoring 1.000
1.0000000000

result:

ok Passed using 682 operation(s): scoring 1.000

Test #5:

score: 5
Accepted
time: 0ms
memory: 6108kb

input:

10
1 8 3 2 6 0 7 9 5 4

output:

68F82AC1898AF4BFACDCBB49543233A61773093A
OK
Passed using 682 operation(s): scoring 1.000
1.0000000000

result:

ok Passed using 682 operation(s): scoring 1.000

Test #6:

score: 5
Accepted
time: 0ms
memory: 6100kb

input:

10
9 7 0 8 3 5 2 6 1 4

output:

68F82AC1898AF4BFACDCBB49543233A61773093A
OK
Passed using 682 operation(s): scoring 1.000
1.0000000000

result:

ok Passed using 682 operation(s): scoring 1.000

Test #7:

score: 5
Accepted
time: 0ms
memory: 5972kb

input:

10
0 1 2 3 4 5 6 7 8 9

output:

68F82AC1898AF4BFACDCBB49543233A61773093A
OK
Passed using 682 operation(s): scoring 1.000
1.0000000000

result:

ok Passed using 682 operation(s): scoring 1.000

Test #8:

score: 5
Accepted
time: 1ms
memory: 5980kb

input:

10
9 8 7 6 5 4 3 2 1 0

output:

68F82AC1898AF4BFACDCBB49543233A61773093A
OK
Passed using 682 operation(s): scoring 1.000
1.0000000000

result:

ok Passed using 682 operation(s): scoring 1.000

Test #9:

score: 5
Accepted
time: 0ms
memory: 5976kb

input:

2
0 1

output:

68F82AC1898AF4BFACDCBB49543233A61773093A
OK
Passed using 186 operation(s): scoring 1.000
1.0000000000

result:

ok Passed using 186 operation(s): scoring 1.000

Test #10:

score: 5
Accepted
time: 0ms
memory: 5940kb

input:

2
1 0

output:

68F82AC1898AF4BFACDCBB49543233A61773093A
OK
Passed using 186 operation(s): scoring 1.000
1.0000000000

result:

ok Passed using 186 operation(s): scoring 1.000

Test #11:

score: 5
Accepted
time: 1ms
memory: 6104kb

input:

4
2 3 0 1

output:

68F82AC1898AF4BFACDCBB49543233A61773093A
OK
Passed using 310 operation(s): scoring 1.000
1.0000000000

result:

ok Passed using 310 operation(s): scoring 1.000

Test #12:

score: 5
Accepted
time: 0ms
memory: 5972kb

input:

4
1 2 0 3

output:

68F82AC1898AF4BFACDCBB49543233A61773093A
OK
Passed using 310 operation(s): scoring 1.000
1.0000000000

result:

ok Passed using 310 operation(s): scoring 1.000

Test #13:

score: 5
Accepted
time: 0ms
memory: 6108kb

input:

4
1 3 0 2

output:

68F82AC1898AF4BFACDCBB49543233A61773093A
OK
Passed using 310 operation(s): scoring 1.000
1.0000000000

result:

ok Passed using 310 operation(s): scoring 1.000

Test #14:

score: 5
Accepted
time: 0ms
memory: 5940kb

input:

5
0 3 4 2 1

output:

68F82AC1898AF4BFACDCBB49543233A61773093A
OK
Passed using 372 operation(s): scoring 1.000
1.0000000000

result:

ok Passed using 372 operation(s): scoring 1.000

Test #15:

score: 5
Accepted
time: 1ms
memory: 6100kb

input:

5
0 2 3 4 1

output:

68F82AC1898AF4BFACDCBB49543233A61773093A
OK
Passed using 372 operation(s): scoring 1.000
1.0000000000

result:

ok Passed using 372 operation(s): scoring 1.000

Test #16:

score: 5
Accepted
time: 0ms
memory: 5976kb

input:

5
3 0 2 4 1

output:

68F82AC1898AF4BFACDCBB49543233A61773093A
OK
Passed using 372 operation(s): scoring 1.000
1.0000000000

result:

ok Passed using 372 operation(s): scoring 1.000

Test #17:

score: 5
Accepted
time: 1ms
memory: 6108kb

input:

5
1 4 3 2 0

output:

68F82AC1898AF4BFACDCBB49543233A61773093A
OK
Passed using 372 operation(s): scoring 1.000
1.0000000000

result:

ok Passed using 372 operation(s): scoring 1.000

Test #18:

score: 5
Accepted
time: 0ms
memory: 6104kb

input:

5
3 4 2 0 1

output:

68F82AC1898AF4BFACDCBB49543233A61773093A
OK
Passed using 372 operation(s): scoring 1.000
1.0000000000

result:

ok Passed using 372 operation(s): scoring 1.000

Test #19:

score: 5
Accepted
time: 1ms
memory: 6108kb

input:

5
0 1 2 3 4

output:

68F82AC1898AF4BFACDCBB49543233A61773093A
OK
Passed using 372 operation(s): scoring 1.000
1.0000000000

result:

ok Passed using 372 operation(s): scoring 1.000

Test #20:

score: 5
Accepted
time: 0ms
memory: 5976kb

input:

5
4 3 2 1 0

output:

68F82AC1898AF4BFACDCBB49543233A61773093A
OK
Passed using 372 operation(s): scoring 1.000
1.0000000000

result:

ok Passed using 372 operation(s): scoring 1.000

Test #21:

score: 5
Accepted
time: 0ms
memory: 6108kb

input:

6
2 4 5 3 1 0

output:

68F82AC1898AF4BFACDCBB49543233A61773093A
OK
Passed using 434 operation(s): scoring 1.000
1.0000000000

result:

ok Passed using 434 operation(s): scoring 1.000

Test #22:

score: 5
Accepted
time: 1ms
memory: 6104kb

input:

6
4 5 0 2 1 3

output:

68F82AC1898AF4BFACDCBB49543233A61773093A
OK
Passed using 434 operation(s): scoring 1.000
1.0000000000

result:

ok Passed using 434 operation(s): scoring 1.000

Test #23:

score: 5
Accepted
time: 0ms
memory: 6104kb

input:

6
5 0 2 3 1 4

output:

68F82AC1898AF4BFACDCBB49543233A61773093A
OK
Passed using 434 operation(s): scoring 1.000
1.0000000000

result:

ok Passed using 434 operation(s): scoring 1.000

Test #24:

score: 5
Accepted
time: 1ms
memory: 6100kb

input:

6
4 3 2 1 0 5

output:

68F82AC1898AF4BFACDCBB49543233A61773093A
OK
Passed using 434 operation(s): scoring 1.000
1.0000000000

result:

ok Passed using 434 operation(s): scoring 1.000

Test #25:

score: 5
Accepted
time: 0ms
memory: 5976kb

input:

6
0 1 2 3 4 5

output:

68F82AC1898AF4BFACDCBB49543233A61773093A
OK
Passed using 434 operation(s): scoring 1.000
1.0000000000

result:

ok Passed using 434 operation(s): scoring 1.000

Test #26:

score: 5
Accepted
time: 1ms
memory: 5976kb

input:

7
0 6 4 2 3 5 1

output:

68F82AC1898AF4BFACDCBB49543233A61773093A
OK
Passed using 496 operation(s): scoring 1.000
1.0000000000

result:

ok Passed using 496 operation(s): scoring 1.000

Test #27:

score: 5
Accepted
time: 0ms
memory: 6104kb

input:

7
3 0 5 4 1 6 2

output:

68F82AC1898AF4BFACDCBB49543233A61773093A
OK
Passed using 496 operation(s): scoring 1.000
1.0000000000

result:

ok Passed using 496 operation(s): scoring 1.000

Test #28:

score: 5
Accepted
time: 0ms
memory: 6104kb

input:

7
0 6 3 2 1 4 5

output:

68F82AC1898AF4BFACDCBB49543233A61773093A
OK
Passed using 496 operation(s): scoring 1.000
1.0000000000

result:

ok Passed using 496 operation(s): scoring 1.000

Test #29:

score: 5
Accepted
time: 1ms
memory: 6108kb

input:

7
0 1 2 3 4 5 6

output:

68F82AC1898AF4BFACDCBB49543233A61773093A
OK
Passed using 496 operation(s): scoring 1.000
1.0000000000

result:

ok Passed using 496 operation(s): scoring 1.000

Test #30:

score: 5
Accepted
time: 0ms
memory: 5976kb

input:

7
6 5 4 3 2 1 0

output:

68F82AC1898AF4BFACDCBB49543233A61773093A
OK
Passed using 496 operation(s): scoring 1.000
1.0000000000

result:

ok Passed using 496 operation(s): scoring 1.000

Test #31:

score: 5
Accepted
time: 1ms
memory: 6108kb

input:

8
0 1 2 3 4 5 6 7

output:

68F82AC1898AF4BFACDCBB49543233A61773093A
OK
Passed using 558 operation(s): scoring 1.000
1.0000000000

result:

ok Passed using 558 operation(s): scoring 1.000

Test #32:

score: 5
Accepted
time: 0ms
memory: 6104kb

input:

9
0 1 2 3 4 5 6 7 8

output:

68F82AC1898AF4BFACDCBB49543233A61773093A
OK
Passed using 620 operation(s): scoring 1.000
1.0000000000

result:

ok Passed using 620 operation(s): scoring 1.000

Test #33:

score: 5
Accepted
time: 1ms
memory: 5972kb

input:

8
7 6 5 4 3 2 1 0

output:

68F82AC1898AF4BFACDCBB49543233A61773093A
OK
Passed using 558 operation(s): scoring 1.000
1.0000000000

result:

ok Passed using 558 operation(s): scoring 1.000

Test #34:

score: 5
Accepted
time: 0ms
memory: 6104kb

input:

9
8 7 6 5 4 3 2 1 0

output:

68F82AC1898AF4BFACDCBB49543233A61773093A
OK
Passed using 620 operation(s): scoring 1.000
1.0000000000

result:

ok Passed using 620 operation(s): scoring 1.000

Test #35:

score: 5
Accepted
time: 0ms
memory: 5976kb

input:

8
5 3 2 1 6 7 0 4

output:

68F82AC1898AF4BFACDCBB49543233A61773093A
OK
Passed using 558 operation(s): scoring 1.000
1.0000000000

result:

ok Passed using 558 operation(s): scoring 1.000

Test #36:

score: 5
Accepted
time: 0ms
memory: 6108kb

input:

8
6 0 3 4 2 7 1 5

output:

68F82AC1898AF4BFACDCBB49543233A61773093A
OK
Passed using 558 operation(s): scoring 1.000
1.0000000000

result:

ok Passed using 558 operation(s): scoring 1.000

Test #37:

score: 5
Accepted
time: 1ms
memory: 6104kb

input:

9
2 5 4 8 6 0 3 1 7

output:

68F82AC1898AF4BFACDCBB49543233A61773093A
OK
Passed using 620 operation(s): scoring 1.000
1.0000000000

result:

ok Passed using 620 operation(s): scoring 1.000

Test #38:

score: 5
Accepted
time: 0ms
memory: 5980kb

input:

9
6 0 4 2 7 3 5 8 1

output:

68F82AC1898AF4BFACDCBB49543233A61773093A
OK
Passed using 620 operation(s): scoring 1.000
1.0000000000

result:

ok Passed using 620 operation(s): scoring 1.000

Test #39:

score: 5
Accepted
time: 0ms
memory: 6104kb

input:

9
2 6 4 0 5 7 1 3 8

output:

68F82AC1898AF4BFACDCBB49543233A61773093A
OK
Passed using 620 operation(s): scoring 1.000
1.0000000000

result:

ok Passed using 620 operation(s): scoring 1.000

Test #40:

score: 5
Accepted
time: 0ms
memory: 5924kb

input:

10
0 7 2 8 5 9 6 3 4 1

output:

68F82AC1898AF4BFACDCBB49543233A61773093A
OK
Passed using 682 operation(s): scoring 1.000
1.0000000000

result:

ok Passed using 682 operation(s): scoring 1.000

Test #41:

score: 5
Accepted
time: 0ms
memory: 5980kb

input:

10
0 9 1 8 6 7 4 3 5 2

output:

68F82AC1898AF4BFACDCBB49543233A61773093A
OK
Passed using 682 operation(s): scoring 1.000
1.0000000000

result:

ok Passed using 682 operation(s): scoring 1.000

Test #42:

score: 5
Accepted
time: 1ms
memory: 6104kb

input:

10
0 7 4 5 8 6 1 3 9 2

output:

68F82AC1898AF4BFACDCBB49543233A61773093A
OK
Passed using 682 operation(s): scoring 1.000
1.0000000000

result:

ok Passed using 682 operation(s): scoring 1.000

Subtask #2:

score: 0
Wrong Answer

Dependency #1:

100%
Accepted

Test #43:

score: 10
Accepted
time: 1ms
memory: 6108kb

input:

70
44 64 19 37 17 65 8 53 6 36 3 30 35 24 34 60 29 56 18 45 1 51 13 23 41 28 49 50 9 21 54 68 27 46 32 57 43 25 67 63 52 47 15 20 58 16 42 39 11 7 4 31 38 69 26 33 2 59 40 66 55 22 0 12 10 48 62 14 5 61

output:

68F82AC1898AF4BFACDCBB49543233A61773093A
OK
Passed using 4402 operation(s): scoring 1.000
1.0000000000

result:

ok Passed using 4402 operation(s): scoring 1.000

Test #44:

score: 10
Accepted
time: 1ms
memory: 6104kb

input:

70
0 30 46 54 34 42 60 23 31 65 11 58 20 3 14 12 40 44 29 10 22 5 50 4 52 49 21 38 53 24 41 37 28 32 59 6 61 9 19 25 35 69 33 64 55 27 17 36 2 67 26 51 8 56 48 43 13 62 63 16 1 15 68 45 39 47 66 18 7 57

output:

68F82AC1898AF4BFACDCBB49543233A61773093A
OK
Passed using 4402 operation(s): scoring 1.000
1.0000000000

result:

ok Passed using 4402 operation(s): scoring 1.000

Test #45:

score: 10
Accepted
time: 0ms
memory: 5932kb

input:

11
4 9 10 1 0 8 7 3 6 5 2

output:

68F82AC1898AF4BFACDCBB49543233A61773093A
OK
Passed using 744 operation(s): scoring 1.000
1.0000000000

result:

ok Passed using 744 operation(s): scoring 1.000

Test #46:

score: 10
Accepted
time: 0ms
memory: 6108kb

input:

14
13 3 9 11 2 6 0 5 10 1 12 8 4 7

output:

68F82AC1898AF4BFACDCBB49543233A61773093A
OK
Passed using 930 operation(s): scoring 1.000
1.0000000000

result:

ok Passed using 930 operation(s): scoring 1.000

Test #47:

score: 10
Accepted
time: 1ms
memory: 5976kb

input:

45
34 32 14 35 18 3 1 42 25 8 37 44 31 15 21 39 0 29 30 40 9 17 10 33 5 4 20 12 38 36 6 23 27 16 41 19 43 2 11 24 22 13 26 28 7

output:

68F82AC1898AF4BFACDCBB49543233A61773093A
OK
Passed using 2852 operation(s): scoring 1.000
1.0000000000

result:

ok Passed using 2852 operation(s): scoring 1.000

Test #48:

score: 10
Accepted
time: 0ms
memory: 5944kb

input:

51
14 15 16 46 1 25 35 0 19 24 8 49 29 44 11 38 23 34 28 4 40 6 9 17 22 5 36 41 13 47 27 45 33 10 48 2 30 32 39 20 50 31 43 7 42 26 21 12 18 37 3

output:

68F82AC1898AF4BFACDCBB49543233A61773093A
OK
Passed using 3224 operation(s): scoring 1.000
1.0000000000

result:

ok Passed using 3224 operation(s): scoring 1.000

Test #49:

score: 10
Accepted
time: 1ms
memory: 5932kb

input:

14
5 0 9 2 8 6 10 1 3 7 13 4 12 11

output:

68F82AC1898AF4BFACDCBB49543233A61773093A
OK
Passed using 930 operation(s): scoring 1.000
1.0000000000

result:

ok Passed using 930 operation(s): scoring 1.000

Test #50:

score: 10
Accepted
time: 1ms
memory: 6100kb

input:

20
9 11 1 18 7 12 19 3 0 4 17 5 14 8 16 6 10 2 15 13

output:

68F82AC1898AF4BFACDCBB49543233A61773093A
OK
Passed using 1302 operation(s): scoring 1.000
1.0000000000

result:

ok Passed using 1302 operation(s): scoring 1.000

Test #51:

score: 10
Accepted
time: 1ms
memory: 5976kb

input:

30
19 4 15 13 22 14 3 5 28 10 26 20 7 2 16 27 11 8 9 12 6 25 24 29 21 17 1 0 18 23

output:

68F82AC1898AF4BFACDCBB49543233A61773093A
OK
Passed using 1922 operation(s): scoring 1.000
1.0000000000

result:

ok Passed using 1922 operation(s): scoring 1.000

Test #52:

score: 10
Accepted
time: 1ms
memory: 5932kb

input:

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

output:

68F82AC1898AF4BFACDCBB49543233A61773093A
OK
Passed using 2542 operation(s): scoring 1.000
1.0000000000

result:

ok Passed using 2542 operation(s): scoring 1.000

Test #53:

score: 10
Accepted
time: 0ms
memory: 5884kb

input:

50
32 1 29 42 19 37 26 10 49 28 5 3 12 0 40 47 9 33 8 21 31 16 24 34 6 7 36 46 45 15 2 20 27 48 4 13 23 30 17 41 38 18 44 39 11 22 25 43 14 35

output:

68F82AC1898AF4BFACDCBB49543233A61773093A
OK
Passed using 3162 operation(s): scoring 1.000
1.0000000000

result:

ok Passed using 3162 operation(s): scoring 1.000

Test #54:

score: 10
Accepted
time: 0ms
memory: 5976kb

input:

60
50 39 25 0 47 28 27 14 4 34 54 56 5 32 35 40 6 8 51 45 59 37 24 49 10 53 41 21 31 16 29 20 1 13 57 55 12 36 58 18 38 15 46 23 2 33 26 48 7 9 22 43 52 42 17 11 30 44 3 19

output:

68F82AC1898AF4BFACDCBB49543233A61773093A
OK
Passed using 3782 operation(s): scoring 1.000
1.0000000000

result:

ok Passed using 3782 operation(s): scoring 1.000

Test #55:

score: 10
Accepted
time: 1ms
memory: 6108kb

input:

70
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 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69

output:

68F82AC1898AF4BFACDCBB49543233A61773093A
OK
Passed using 4402 operation(s): scoring 1.000
1.0000000000

result:

ok Passed using 4402 operation(s): scoring 1.000

Test #56:

score: 10
Accepted
time: 1ms
memory: 5980kb

input:

70
69 68 67 66 65 64 63 62 61 60 59 58 57 56 55 54 53 52 51 50 49 48 47 46 45 44 43 42 41 40 39 38 37 36 35 34 33 32 31 30 29 28 27 26 25 24 23 22 21 20 19 18 17 16 15 14 13 12 11 10 9 8 7 6 5 4 3 2 1 0

output:

68F82AC1898AF4BFACDCBB49543233A61773093A
OK
Passed using 4402 operation(s): scoring 1.000
1.0000000000

result:

ok Passed using 4402 operation(s): scoring 1.000

Test #57:

score: 10
Accepted
time: 0ms
memory: 6108kb

input:

70
0 69 68 67 66 65 64 63 62 61 60 59 58 57 56 55 54 53 52 51 50 49 48 47 46 45 44 43 42 41 40 39 38 37 36 35 34 33 32 31 30 29 28 27 26 25 24 23 22 21 20 19 18 17 16 15 14 13 12 11 10 9 8 7 6 5 4 3 2 1

output:

68F82AC1898AF4BFACDCBB49543233A61773093A
OK
Passed using 4402 operation(s): scoring 1.000
1.0000000000

result:

ok Passed using 4402 operation(s): scoring 1.000

Test #58:

score: 0
Wrong Answer
time: 0ms
memory: 5972kb

input:

70
5 11 49 41 36 1 38 31 54 20 6 33 39 9 22 52 21 61 17 7 26 40 57 48 65 58 28 30 55 13 18 56 4 14 50 27 42 16 67 15 47 12 64 51 19 44 8 69 35 45 24 62 63 34 53 29 37 46 68 60 23 59 2 10 32 66 43 25 0 3

output:

68F82AC1898AF4BFACDCBB49543233A61773093A
WA
Incorrect answer: p_2 is expected to be 49 but found 65

result:

wrong answer Incorrect answer: p_2 is expected to be 49 but found 65

Subtask #3:

score: 0
Skipped

Dependency #2:

0%

Subtask #4:

score: 0
Time Limit Exceeded

Test #84:

score: 0
Time Limit Exceeded

input:

5000
0 4022 1149 1576 2995 1809 3803 4188 1400 1251 4042 2830 766 4811 1622 4002 4474 1003 1152 130 4794 1902 1292 968 4673 3459 1795 3812 531 2335 1660 4968 3632 4047 353 4448 2515 1581 4259 1389 3628 3760 1381 2527 2353 4323 2807 386 1731 1973 1209 1982 232 747 2904 897 4375 2921 3384 457 1050 936...

output:


result:


Subtask #5:

score: 0
Skipped

Dependency #3:

0%