QOJ.ac

QOJ

ID题目提交者结果用时内存语言文件大小提交时间测评时间
#364337#8237. Sugar Sweet IIkingsnow_2WA 0ms3824kbC++141.3kb2024-03-24 13:49:152024-03-24 13:49:15

Judging History

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

  • [2024-11-04 16:59:03]
  • hack成功,自动添加数据
  • (/hack/1109)
  • [2024-03-24 13:49:15]
  • 评测
  • 测评结果:WA
  • 用时:0ms
  • 内存:3824kb
  • [2024-03-24 13:49:15]
  • 提交

answer

//#pragma GCC optimize(3,"Ofast","inline")
//#pragma GCC optimize("-Ofast","-funroll-all-loops")
#include<bits/stdc++.h>
//#define getchar nc
#define sight(c) ('0'<=c&&c<='9')
#define LL long long
#define debug(a) cout<<#a<<" is "<<a<<"\n"
#define dput(a) puts("a")
#define eho(x) for(int i=head[x];i;i=net[i])
#define fi first
#define se second
inline char nc(){
static char buf[1000000],*p1=buf,*p2=buf;
return p1==p2&&(p2=(p1=buf)+fread(buf,1,1000000,stdin),p1==p2)?EOF:*p1++;
}
template <class T>
inline void read(T &x){// unsigned
    static char c;
    for (c=getchar();!sight(c);c=getchar());
    for (x=0;sight(c);c=getchar())x=x*10+c-48;
}
template <class T> void write(T x){if (x<10) {putchar('0'+x); return;} write(x/10); putchar('0'+x%10);}
template <class T> inline void writeln(T x){ if (x<0) putchar('-'),x*=-1; write(x); putchar('\n'); }
template <class T> inline void writel(T x){ if (x<0) putchar('-'),x*=-1; write(x); putchar(' '); }
using namespace std;
int T,n; 
signed main() {
	#ifdef LOCAL
	//	freopen("test.in", "r", stdin);
	//	freopen("test.out", "w", stdout);
	#endif
	scanf("%d",&T);
	while (T--) {
		scanf("%d",&n);
		printf("%d ",2*n-3);
		for (int i=1;i<n;i++) printf("%d %d ",2,-1);
		printf("%d\n",1);
	} 
    return 0;
}

详细

Test #1:

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

input:

4
4
2 5 5 2
4 2 1 3
3 2 1 4
3
5 4 3
1 1 1
6 6 6
3
5 4 3
2 3 1
1 2 3
5
2 1 3 2 1
5 1 1 3 4
1 3 4 2 4

output:

5 2 -1 2 -1 2 -1 1
1 2 -1 1
7 2 -1 2 -1 2 -1 2 -1 1
7 2 -1 2 -1 2 -1 2 -1 1

result:

wrong answer 1st numbers differ - expected: '500000007', found: '5'