ID | 题目 | 提交者 | 结果 | 用时 | 内存 | 语言 | 文件大小 | 提交时间 | 测评时间 |
---|---|---|---|---|---|---|---|---|---|
#215048 | #2705. Yet another lights out | a_sad_soul | 5 | 0ms | 1204kb | C++11 | 406b | 2024-11-25 21:19:59 | 2024-11-25 23:11:54 |
answer
#include<bits/stdc++.h>
using namespace std;
char s[200][200];
int main(){
int T;
cin>>T;
while(T--){
int n,m;scanf("%d%d",&n,&m);bool fail=0;
for(int i=2;i<n;++i)
for(int j=2;j<m;++j)
if(s[i][j]=='B'&&s[i+1][j]=='W'&&s[i-1][j]=='W'&&s[i][j+1]=='W'&&s[i][j-1]=='W'){puts("No");fail=1;}
if(!fail)puts("No");
}
return 0;
}
详细
小提示:点击横条可展开更详细的信息
Test #1:
score: 0
Wrong Answer
time: 0ms
memory: 1200kb
input:
10 3 4 BBBB BWBW WBBW 3 4 WBWB WBBB WBBW 4 4 BWBB BWWB WWBB WBWB 4 3 WBB BBW BWB WBB 4 3 WBB BWW WWW...
output:
No No No No No No No No No No
result:
wrong answer 3rd lines differ - expected: 'Yes', found: 'No'
Test #2:
score: 0
Wrong Answer
time: 0ms
memory: 1204kb
input:
10 4 3 BWB BWW WWB WBW 3 3 BBW WBW BBW 3 4 WBWB BBWB BBWW 3 3 WBW BWW BWW 4 4 WWBB BWWB BWWB BBBW 3 ...
output:
No No No No No No No No No No
result:
wrong answer 5th lines differ - expected: 'Yes', found: 'No'
Test #3:
score: 0
Wrong Answer
time: 0ms
memory: 1204kb
input:
10 3 3 WBB BWW BBW 4 3 WBB BWW BBB WBW 4 4 BWWB WWWB WBBB WBBB 4 4 WBWB WBBB WBBB WBBW 3 3 WBW BBB B...
output:
No No No No No No No No No No
result:
wrong answer 3rd lines differ - expected: 'Yes', found: 'No'
Test #4:
score: 0
Wrong Answer
time: 0ms
memory: 1204kb
input:
10 3 3 BWB WWW BBB 4 3 BWW BWW BBB WBW 4 4 BWBW BWWW BBWW WWWW 3 3 BBB BBB BWW 4 3 WBB WBW BWW WBB 3...
output:
No No No No No No No No No No
result:
wrong answer 2nd lines differ - expected: 'Yes', found: 'No'
Test #5:
score: 5
Accepted
time: 0ms
memory: 1204kb
input:
10 15 14 WWWWWWWWBBWBWW WWBWWBWBWWWWWB WBWWBBWWBBBBBB WBBWBWWBWWBWWB WBBBBBBWBBWWBW BWBWWWBBWBBWWW B...
output:
No No No No No No No No No No
result:
ok 10 lines
Test #6:
score: 0
Wrong Answer
time: 0ms
memory: 1204kb
input:
10 15 15 BBBWBWWWWBWBWWW BBBBWBWBBBBWWWB BBBBBBBBBBBBWWB WBBBWWWBBBBWBBW BWBBWBWBWWWWWBB BBWWWWBWBBW...
output:
No No No No No No No No No No
result:
wrong answer 2nd lines differ - expected: 'Yes', found: 'No'
Test #7:
score: 0
Wrong Answer
time: 0ms
memory: 1204kb
input:
10 14 14 WBWBBWWWWBBWBB BBWWWBBBWBBWWB BWBWWBBWBWBWBW BBWBWWBWWWBWWB WBWWBBBWBWWWBW WWBWBBBBBWWWBB W...
output:
No No No No No No No No No No
result:
wrong answer 1st lines differ - expected: 'Yes', found: 'No'
Test #8:
score: 0
Wrong Answer
time: 0ms
memory: 1204kb
input:
10 15 15 BBBBBBBWWWWBWWW BBWWWBWWBBWBBWB BWWBBBBWBBBWWBW WBWWBBWBWBBWBWW BWBWWWBBBBWWWWB WWWBBWWWBWW...
output:
No No No No No No No No No No
result:
wrong answer 4th lines differ - expected: 'Yes', found: 'No'
Test #9:
score: 0
Wrong Answer
time: 0ms
memory: 1204kb
input:
10 15 15 WBBWWWBBWWWWBWW BWWWWWBBBWBBBBB BWWWWWBWBWWWBWW WWWWBBBWWBWBBBB BWWWWWBWWBWBBWW WWWWBWBWBBB...
output:
No No No No No No No No No No
result:
wrong answer 4th lines differ - expected: 'Yes', found: 'No'
Test #10:
score: 0
Wrong Answer
time: 0ms
memory: 1200kb
input:
10 14 14 WBWWBBBBWWBBWB BWWWWBBWWBBWBB BWWBWWWBWWBWBW BWBBWBBWWBWWWW BBWBWWWBBBBBBB WWWWBWBBBBBWBB W...
output:
No No No No No No No No No No
result:
wrong answer 1st lines differ - expected: 'Yes', found: 'No'
Test #11:
score: 0
Wrong Answer
time: 0ms
memory: 1200kb
input:
10 99 100 BBBBBWBBBWWWBWBWWBBBWBWWBWWBBWBBWWBWWBWWBBWWWBWBWBWBBBWWBBBWWWWBBBBWWWBWWBWWBWBBWWWWBWWWWW...
output:
No No No No No No No No No No
result:
wrong answer 2nd lines differ - expected: 'Yes', found: 'No'
Test #12:
score: 0
Wrong Answer
time: 0ms
memory: 1200kb
input:
10 99 99 BWWBWBWBBBBWWBWWWBBBBWWBBBBBWBWBBWBWWBBWBBBBWBWBBBWBWBBWWWWBBBWBWWBBBBBBWBBWWBBBBWWBWBWWBWB...
output:
No No No No No No No No No No
result:
wrong answer 3rd lines differ - expected: 'Yes', found: 'No'
Test #13:
score: 0
Wrong Answer
time: 0ms
memory: 1200kb
input:
10 99 99 WBWBBWWWBWWBBWBWBWWBBWBWWBBWBBBWBBBWWWWWBWWBBBBBBWBBBWBBBBBWBBBWWBBWWBBBBBWWBWBBBBBBWBWBBBB...
output:
No No No No No No No No No No
result:
wrong answer 2nd lines differ - expected: 'Yes', found: 'No'
Test #14:
score: 0
Wrong Answer
time: 0ms
memory: 1204kb
input:
10 100 99 BWBWBWWBBWBBBBWWBWBWWBWBBBBBWBBWWBWWBWWWBWBWBBWBWBBBWBBBBWBWBBWWBWWBWWBWBBWWWWWBBBBBWWWBWW...
output:
No No No No No No No No No No
result:
wrong answer 3rd lines differ - expected: 'Yes', found: 'No'
Test #15:
score: 0
Wrong Answer
time: 0ms
memory: 1204kb
input:
10 99 99 WBBBWWBWBBWBWWBWBWWBWWBWBWWWBBBBWWWBBWWWBWBWWWWBBWWWBWBBBBWWBWWWWWBBBWWBBBWBBBBBBWWBWBBWWWW...
output:
No No No No No No No No No No
result:
wrong answer 3rd lines differ - expected: 'Yes', found: 'No'
Test #16:
score: 0
Wrong Answer
time: 0ms
memory: 1200kb
input:
10 100 100 WBBWWBWBWWWWWBBBWBWWWWBWWWBBWWWBBWWWWWBWWBBWBBWWBBWBBWBBBBWWBBWBBWWBWBBWBBWBWWBBWBWWWBBWW...
output:
No No No No No No No No No No
result:
wrong answer 1st lines differ - expected: 'Yes', found: 'No'
Test #17:
score: 0
Wrong Answer
time: 0ms
memory: 1204kb
input:
10 99 100 WBWWWBWWWWWWBWBBWBWBWWWBWWBBWWBBBWBBBBBBBBBWWBBWWWWWBBWWWBWWWBBWWBWWWWWBBWWWBWWWWBBBWWBWBB...
output:
No No No No No No No No No No
result:
wrong answer 5th lines differ - expected: 'Yes', found: 'No'
Test #18:
score: 0
Wrong Answer
time: 0ms
memory: 1204kb
input:
10 100 99 BBBWWWBBWBBBBBBWBBWBWWBWBBBWWWBBBWBWBWBBBBWBWWWBBWWBBBWWWBBBWWWBBBBWBWBWBWBWBWWBWWWBWBBBBW...
output:
No No No No No No No No No No
result:
wrong answer 5th lines differ - expected: 'Yes', found: 'No'
Test #19:
score: 0
Wrong Answer
time: 0ms
memory: 1204kb
input:
10 100 99 BWBBWWWBWWWBBWBWBBWWWBWWWBBWWWBWWBBBWBWBWBBBBWBBBWWBBBWBWWBWWWBWBBBWBBWBBBBBBBBWWWWBBBBWWW...
output:
No No No No No No No No No No
result:
wrong answer 6th lines differ - expected: 'Yes', found: 'No'
Test #20:
score: 0
Wrong Answer
time: 0ms
memory: 1204kb
input:
10 99 99 WWBWBWBWBWBBBBWBBBBWWWBWWWWBBBBBBBBBWBWWBBWWBBWWWBBWWWBWWWBBWWWWWBWBWWBWWWBWBWBWWWBBWBBBWWB...
output:
No No No No No No No No No No
result:
wrong answer 8th lines differ - expected: 'Yes', found: 'No'