QOJ.ac

QOJ

ID题目提交者结果用时内存语言文件大小提交时间测评时间
#235329#6819. Largest Unique Winszyfy#AC ✓3ms3564kbC++14577b2023-11-02 17:17:322023-11-02 17:17:32

Judging History

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

  • [2023-11-02 17:17:32]
  • 评测
  • 测评结果:AC
  • 用时:3ms
  • 内存:3564kb
  • [2023-11-02 17:17:32]
  • 提交

answer

#include <bits/stdc++.h>
#define int long long
#define lowbit(x) x & (-x)
using namespace std;
const int mod = 1000000007;


void solve() {
    int n, m; cin >> n >> m;
    int now = m;
    for(int i = 1; i <= n; i++) {
        for(int j = 1; j <= m; j++) {
            if(j == now) cout << 1 << ' ';
            else cout << 0 << ' ';
        } cout << '\n';
        if(i % 2 == 0) now--;
        if(now == 0) now = 1;
    }
    
}


signed main() {
	ios::sync_with_stdio(false);
	int tt = 1;
	// cin >> tt;
	while (tt--) {
		solve();
	}
}




这程序好像有点Bug,我给组数据试试?

详细

Test #1:

score: 100
Accepted
time: 1ms
memory: 3352kb

input:

2 2

output:

0 1 
0 1 

result:

ok ok  0.0000 0.0000

Test #2:

score: 0
Accepted
time: 1ms
memory: 3396kb

input:

3 3

output:

0 0 1 
0 0 1 
0 1 0 

result:

ok ok  -1.0000 -1.0000 1.0000

Test #3:

score: 0
Accepted
time: 0ms
memory: 3352kb

input:

3 2

output:

0 1 
0 1 
1 0 

result:

ok ok  -1.0000 -1.0000 1.0000

Test #4:

score: 0
Accepted
time: 0ms
memory: 3396kb

input:

12 12

output:

0 0 0 0 0 0 0 0 0 0 0 1 
0 0 0 0 0 0 0 0 0 0 0 1 
0 0 0 0 0 0 0 0 0 0 1 0 
0 0 0 0 0 0 0 0 0 0 1 0 
0 0 0 0 0 0 0 0 0 1 0 0 
0 0 0 0 0 0 0 0 0 1 0 0 
0 0 0 0 0 0 0 0 1 0 0 0 
0 0 0 0 0 0 0 0 1 0 0 0 
0 0 0 0 0 0 0 1 0 0 0 0 
0 0 0 0 0 0 0 1 0 0 0 0 
0 0 0 0 0 0 1 0 0 0 0 0 
0 0 0 0 0 0 1 0 0 0 0 0 

result:

ok ok  0.0000 0.0000 0.0000 0.0000 0.0000 0.0000 0.0000 0.0000 0.0000 0.0000 0.0000 0.0000

Test #5:

score: 0
Accepted
time: 0ms
memory: 3388kb

input:

12 11

output:

0 0 0 0 0 0 0 0 0 0 1 
0 0 0 0 0 0 0 0 0 0 1 
0 0 0 0 0 0 0 0 0 1 0 
0 0 0 0 0 0 0 0 0 1 0 
0 0 0 0 0 0 0 0 1 0 0 
0 0 0 0 0 0 0 0 1 0 0 
0 0 0 0 0 0 0 1 0 0 0 
0 0 0 0 0 0 0 1 0 0 0 
0 0 0 0 0 0 1 0 0 0 0 
0 0 0 0 0 0 1 0 0 0 0 
0 0 0 0 0 1 0 0 0 0 0 
0 0 0 0 0 1 0 0 0 0 0 

result:

ok ok  0.0000 0.0000 0.0000 0.0000 0.0000 0.0000 0.0000 0.0000 0.0000 0.0000 0.0000 0.0000

Test #6:

score: 0
Accepted
time: 1ms
memory: 3352kb

input:

11 12

output:

0 0 0 0 0 0 0 0 0 0 0 1 
0 0 0 0 0 0 0 0 0 0 0 1 
0 0 0 0 0 0 0 0 0 0 1 0 
0 0 0 0 0 0 0 0 0 0 1 0 
0 0 0 0 0 0 0 0 0 1 0 0 
0 0 0 0 0 0 0 0 0 1 0 0 
0 0 0 0 0 0 0 0 1 0 0 0 
0 0 0 0 0 0 0 0 1 0 0 0 
0 0 0 0 0 0 0 1 0 0 0 0 
0 0 0 0 0 0 0 1 0 0 0 0 
0 0 0 0 0 0 1 0 0 0 0 0 

result:

ok ok  -1.0000 -1.0000 -1.0000 -1.0000 -1.0000 -1.0000 -1.0000 -1.0000 -1.0000 -1.0000 1.0000

Test #7:

score: 0
Accepted
time: 0ms
memory: 3392kb

input:

12 3

output:

0 0 1 
0 0 1 
0 1 0 
0 1 0 
1 0 0 
1 0 0 
1 0 0 
1 0 0 
1 0 0 
1 0 0 
1 0 0 
1 0 0 

result:

ok ok  0.0000 0.0000 0.0000 0.0000 0.0000 0.0000 0.0000 0.0000 0.0000 0.0000 0.0000 0.0000

Test #8:

score: 0
Accepted
time: 0ms
memory: 3396kb

input:

2 12

output:

0 0 0 0 0 0 0 0 0 0 0 1 
0 0 0 0 0 0 0 0 0 0 0 1 

result:

ok ok  0.0000 0.0000

Test #9:

score: 0
Accepted
time: 1ms
memory: 3332kb

input:

4 12

output:

0 0 0 0 0 0 0 0 0 0 0 1 
0 0 0 0 0 0 0 0 0 0 0 1 
0 0 0 0 0 0 0 0 0 0 1 0 
0 0 0 0 0 0 0 0 0 0 1 0 

result:

ok ok  0.0000 0.0000 0.0000 0.0000

Test #10:

score: 0
Accepted
time: 1ms
memory: 3364kb

input:

12 4

output:

0 0 0 1 
0 0 0 1 
0 0 1 0 
0 0 1 0 
0 1 0 0 
0 1 0 0 
1 0 0 0 
1 0 0 0 
1 0 0 0 
1 0 0 0 
1 0 0 0 
1 0 0 0 

result:

ok ok  0.0000 0.0000 0.0000 0.0000 0.0000 0.0000 0.0000 0.0000 0.0000 0.0000 0.0000 0.0000

Test #11:

score: 0
Accepted
time: 1ms
memory: 3432kb

input:

3 12

output:

0 0 0 0 0 0 0 0 0 0 0 1 
0 0 0 0 0 0 0 0 0 0 0 1 
0 0 0 0 0 0 0 0 0 0 1 0 

result:

ok ok  -1.0000 -1.0000 1.0000

Test #12:

score: 0
Accepted
time: 1ms
memory: 3564kb

input:

4 5

output:

0 0 0 0 1 
0 0 0 0 1 
0 0 0 1 0 
0 0 0 1 0 

result:

ok ok  0.0000 0.0000 0.0000 0.0000

Test #13:

score: 0
Accepted
time: 1ms
memory: 3296kb

input:

4 9

output:

0 0 0 0 0 0 0 0 1 
0 0 0 0 0 0 0 0 1 
0 0 0 0 0 0 0 1 0 
0 0 0 0 0 0 0 1 0 

result:

ok ok  0.0000 0.0000 0.0000 0.0000

Test #14:

score: 0
Accepted
time: 1ms
memory: 3396kb

input:

9 5

output:

0 0 0 0 1 
0 0 0 0 1 
0 0 0 1 0 
0 0 0 1 0 
0 0 1 0 0 
0 0 1 0 0 
0 1 0 0 0 
0 1 0 0 0 
1 0 0 0 0 

result:

ok ok  -1.0000 -1.0000 -1.0000 -1.0000 -1.0000 -1.0000 -1.0000 -1.0000 1.0000

Test #15:

score: 0
Accepted
time: 0ms
memory: 3552kb

input:

10 5

output:

0 0 0 0 1 
0 0 0 0 1 
0 0 0 1 0 
0 0 0 1 0 
0 0 1 0 0 
0 0 1 0 0 
0 1 0 0 0 
0 1 0 0 0 
1 0 0 0 0 
1 0 0 0 0 

result:

ok ok  0.0000 0.0000 0.0000 0.0000 0.0000 0.0000 0.0000 0.0000 0.0000 0.0000

Test #16:

score: 0
Accepted
time: 3ms
memory: 3400kb

input:

11 5

output:

0 0 0 0 1 
0 0 0 0 1 
0 0 0 1 0 
0 0 0 1 0 
0 0 1 0 0 
0 0 1 0 0 
0 1 0 0 0 
0 1 0 0 0 
1 0 0 0 0 
1 0 0 0 0 
1 0 0 0 0 

result:

ok ok  0.0000 0.0000 0.0000 0.0000 0.0000 0.0000 0.0000 0.0000 0.0000 0.0000 0.0000

Test #17:

score: 0
Accepted
time: 1ms
memory: 3388kb

input:

11 6

output:

0 0 0 0 0 1 
0 0 0 0 0 1 
0 0 0 0 1 0 
0 0 0 0 1 0 
0 0 0 1 0 0 
0 0 0 1 0 0 
0 0 1 0 0 0 
0 0 1 0 0 0 
0 1 0 0 0 0 
0 1 0 0 0 0 
1 0 0 0 0 0 

result:

ok ok  -1.0000 -1.0000 -1.0000 -1.0000 -1.0000 -1.0000 -1.0000 -1.0000 -1.0000 -1.0000 1.0000

Test #18:

score: 0
Accepted
time: 0ms
memory: 3520kb

input:

12 6

output:

0 0 0 0 0 1 
0 0 0 0 0 1 
0 0 0 0 1 0 
0 0 0 0 1 0 
0 0 0 1 0 0 
0 0 0 1 0 0 
0 0 1 0 0 0 
0 0 1 0 0 0 
0 1 0 0 0 0 
0 1 0 0 0 0 
1 0 0 0 0 0 
1 0 0 0 0 0 

result:

ok ok  0.0000 0.0000 0.0000 0.0000 0.0000 0.0000 0.0000 0.0000 0.0000 0.0000 0.0000 0.0000

Test #19:

score: 0
Accepted
time: 1ms
memory: 3392kb

input:

12 5

output:

0 0 0 0 1 
0 0 0 0 1 
0 0 0 1 0 
0 0 0 1 0 
0 0 1 0 0 
0 0 1 0 0 
0 1 0 0 0 
0 1 0 0 0 
1 0 0 0 0 
1 0 0 0 0 
1 0 0 0 0 
1 0 0 0 0 

result:

ok ok  0.0000 0.0000 0.0000 0.0000 0.0000 0.0000 0.0000 0.0000 0.0000 0.0000 0.0000 0.0000

Test #20:

score: 0
Accepted
time: 0ms
memory: 3404kb

input:

12 7

output:

0 0 0 0 0 0 1 
0 0 0 0 0 0 1 
0 0 0 0 0 1 0 
0 0 0 0 0 1 0 
0 0 0 0 1 0 0 
0 0 0 0 1 0 0 
0 0 0 1 0 0 0 
0 0 0 1 0 0 0 
0 0 1 0 0 0 0 
0 0 1 0 0 0 0 
0 1 0 0 0 0 0 
0 1 0 0 0 0 0 

result:

ok ok  0.0000 0.0000 0.0000 0.0000 0.0000 0.0000 0.0000 0.0000 0.0000 0.0000 0.0000 0.0000

Test #21:

score: 0
Accepted
time: 0ms
memory: 3360kb

input:

5 12

output:

0 0 0 0 0 0 0 0 0 0 0 1 
0 0 0 0 0 0 0 0 0 0 0 1 
0 0 0 0 0 0 0 0 0 0 1 0 
0 0 0 0 0 0 0 0 0 0 1 0 
0 0 0 0 0 0 0 0 0 1 0 0 

result:

ok ok  -1.0000 -1.0000 -1.0000 -1.0000 1.0000

Test #22:

score: 0
Accepted
time: 1ms
memory: 3376kb

input:

9 12

output:

0 0 0 0 0 0 0 0 0 0 0 1 
0 0 0 0 0 0 0 0 0 0 0 1 
0 0 0 0 0 0 0 0 0 0 1 0 
0 0 0 0 0 0 0 0 0 0 1 0 
0 0 0 0 0 0 0 0 0 1 0 0 
0 0 0 0 0 0 0 0 0 1 0 0 
0 0 0 0 0 0 0 0 1 0 0 0 
0 0 0 0 0 0 0 0 1 0 0 0 
0 0 0 0 0 0 0 1 0 0 0 0 

result:

ok ok  -1.0000 -1.0000 -1.0000 -1.0000 -1.0000 -1.0000 -1.0000 -1.0000 1.0000

Test #23:

score: 0
Accepted
time: 1ms
memory: 3512kb

input:

12 9

output:

0 0 0 0 0 0 0 0 1 
0 0 0 0 0 0 0 0 1 
0 0 0 0 0 0 0 1 0 
0 0 0 0 0 0 0 1 0 
0 0 0 0 0 0 1 0 0 
0 0 0 0 0 0 1 0 0 
0 0 0 0 0 1 0 0 0 
0 0 0 0 0 1 0 0 0 
0 0 0 0 1 0 0 0 0 
0 0 0 0 1 0 0 0 0 
0 0 0 1 0 0 0 0 0 
0 0 0 1 0 0 0 0 0 

result:

ok ok  0.0000 0.0000 0.0000 0.0000 0.0000 0.0000 0.0000 0.0000 0.0000 0.0000 0.0000 0.0000

Test #24:

score: 0
Accepted
time: 1ms
memory: 3516kb

input:

12 10

output:

0 0 0 0 0 0 0 0 0 1 
0 0 0 0 0 0 0 0 0 1 
0 0 0 0 0 0 0 0 1 0 
0 0 0 0 0 0 0 0 1 0 
0 0 0 0 0 0 0 1 0 0 
0 0 0 0 0 0 0 1 0 0 
0 0 0 0 0 0 1 0 0 0 
0 0 0 0 0 0 1 0 0 0 
0 0 0 0 0 1 0 0 0 0 
0 0 0 0 0 1 0 0 0 0 
0 0 0 0 1 0 0 0 0 0 
0 0 0 0 1 0 0 0 0 0 

result:

ok ok  0.0000 0.0000 0.0000 0.0000 0.0000 0.0000 0.0000 0.0000 0.0000 0.0000 0.0000 0.0000

Test #25:

score: 0
Accepted
time: 0ms
memory: 3400kb

input:

10 12

output:

0 0 0 0 0 0 0 0 0 0 0 1 
0 0 0 0 0 0 0 0 0 0 0 1 
0 0 0 0 0 0 0 0 0 0 1 0 
0 0 0 0 0 0 0 0 0 0 1 0 
0 0 0 0 0 0 0 0 0 1 0 0 
0 0 0 0 0 0 0 0 0 1 0 0 
0 0 0 0 0 0 0 0 1 0 0 0 
0 0 0 0 0 0 0 0 1 0 0 0 
0 0 0 0 0 0 0 1 0 0 0 0 
0 0 0 0 0 0 0 1 0 0 0 0 

result:

ok ok  0.0000 0.0000 0.0000 0.0000 0.0000 0.0000 0.0000 0.0000 0.0000 0.0000

Test #26:

score: 0
Accepted
time: 1ms
memory: 3380kb

input:

2 3

output:

0 0 1 
0 0 1 

result:

ok ok  0.0000 0.0000

Test #27:

score: 0
Accepted
time: 0ms
memory: 3296kb

input:

2 4

output:

0 0 0 1 
0 0 0 1 

result:

ok ok  0.0000 0.0000

Test #28:

score: 0
Accepted
time: 0ms
memory: 3336kb

input:

2 5

output:

0 0 0 0 1 
0 0 0 0 1 

result:

ok ok  0.0000 0.0000

Test #29:

score: 0
Accepted
time: 0ms
memory: 3352kb

input:

12 2

output:

0 1 
0 1 
1 0 
1 0 
1 0 
1 0 
1 0 
1 0 
1 0 
1 0 
1 0 
1 0 

result:

ok ok  0.0000 0.0000 0.0000 0.0000 0.0000 0.0000 0.0000 0.0000 0.0000 0.0000 0.0000 0.0000

Test #30:

score: 0
Accepted
time: 0ms
memory: 3332kb

input:

4 2

output:

0 1 
0 1 
1 0 
1 0 

result:

ok ok  0.0000 0.0000 0.0000 0.0000

Test #31:

score: 0
Accepted
time: 1ms
memory: 3524kb

input:

5 2

output:

0 1 
0 1 
1 0 
1 0 
1 0 

result:

ok ok  0.0000 0.0000 0.0000 0.0000 0.0000

Test #32:

score: 0
Accepted
time: 0ms
memory: 3508kb

input:

7 9

output:

0 0 0 0 0 0 0 0 1 
0 0 0 0 0 0 0 0 1 
0 0 0 0 0 0 0 1 0 
0 0 0 0 0 0 0 1 0 
0 0 0 0 0 0 1 0 0 
0 0 0 0 0 0 1 0 0 
0 0 0 0 0 1 0 0 0 

result:

ok ok  -1.0000 -1.0000 -1.0000 -1.0000 -1.0000 -1.0000 1.0000

Test #33:

score: 0
Accepted
time: 0ms
memory: 3396kb

input:

6 9

output:

0 0 0 0 0 0 0 0 1 
0 0 0 0 0 0 0 0 1 
0 0 0 0 0 0 0 1 0 
0 0 0 0 0 0 0 1 0 
0 0 0 0 0 0 1 0 0 
0 0 0 0 0 0 1 0 0 

result:

ok ok  0.0000 0.0000 0.0000 0.0000 0.0000 0.0000

Test #34:

score: 0
Accepted
time: 0ms
memory: 3388kb

input:

6 10

output:

0 0 0 0 0 0 0 0 0 1 
0 0 0 0 0 0 0 0 0 1 
0 0 0 0 0 0 0 0 1 0 
0 0 0 0 0 0 0 0 1 0 
0 0 0 0 0 0 0 1 0 0 
0 0 0 0 0 0 0 1 0 0 

result:

ok ok  0.0000 0.0000 0.0000 0.0000 0.0000 0.0000