ID | 题目 | 提交者 | 结果 | 用时 | 内存 | 语言 | 文件大小 | 提交时间 | 测评时间 |
---|---|---|---|---|---|---|---|---|---|
#211912 | #3433. Crisscross | wushuyu | 10 | 298ms | 3476kb | C++11 | 434b | 2024-10-12 20:03:56 | 2024-10-12 20:03:58 |
answer
#include<bits/stdc++.h>
using namespace std;
long long n,m,cnt;
string str[10000],qqq[10000];
int main()
{
cin>>n>>m;
for(int i=1;i<=n;i++)
cin>>str[i];
for(int i=0;i<m;i++)
{
for(int j=1;j<=n;j++)
{
qqq[i]+=str[j][i];
}
}
for(int i=1;i<=n;i++)
{
if(str[i]==string(m,'1')) cnt++;
}
for(int i=0;i<m;i++)
{
if(qqq[i]==string(n,'1')) cnt++;
}
cout<<n+m-cnt;
return 0;
}
详细
小提示:点击横条可展开更详细的信息
Test #1:
score: 10
Accepted
time: 0ms
memory: 1396kb
input:
4 4 1111 1011 1100 1100
output:
6
result:
ok 1 number(s): "6"
Test #2:
score: 0
Wrong Answer
time: 0ms
memory: 1444kb
input:
1 1000 011001110110011101110110000011110011001001110111010001110001110100100010011010001001110111100...
output:
487
result:
wrong answer 1st numbers differ - expected: '488', found: '487'
Test #3:
score: 0
Wrong Answer
time: 0ms
memory: 1448kb
input:
1 1000 001110111101111001001110111111000101001110110110101100001111010001101111010100010010010001011...
output:
481
result:
wrong answer 1st numbers differ - expected: '482', found: '481'
Test #4:
score: 0
Wrong Answer
time: 34ms
memory: 3472kb
input:
1000 1000 010101000000101000010101111101010010100110110001100011110010100001010011001010110001001101...
output:
2000
result:
wrong answer 1st numbers differ - expected: '2001', found: '2000'
Test #5:
score: 0
Wrong Answer
time: 59ms
memory: 3472kb
input:
1000 1000 000001101010101101101001010100001000011110100000011011010101000000000111001011010110011110...
output:
2000
result:
wrong answer 1st numbers differ - expected: '2001', found: '2000'
Test #6:
score: 0
Wrong Answer
time: 64ms
memory: 3472kb
input:
1000 1000 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000...
output:
2000
result:
wrong answer 1st numbers differ - expected: '2001', found: '2000'
Test #7:
score: 0
Wrong Answer
time: 39ms
memory: 3476kb
input:
1000 1000 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000...
output:
2000
result:
wrong answer 1st numbers differ - expected: '2001', found: '2000'
Test #8:
score: 0
Wrong Answer
time: 34ms
memory: 3472kb
input:
1000 1000 100000010101010111000001011110000000001100000011110001110010101011110100000010011000011100...
output:
2000
result:
wrong answer 1st numbers differ - expected: '2001', found: '2000'
Test #9:
score: 0
Wrong Answer
time: 36ms
memory: 3472kb
input:
1000 1000 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000...
output:
2000
result:
wrong answer 1st numbers differ - expected: '2001', found: '2000'
Test #10:
score: 0
Wrong Answer
time: 32ms
memory: 3476kb
input:
1000 1000 110001000111111010010100001000100011010001001101000001001001010111010101010111111110100001...
output:
2000
result:
wrong answer 1st numbers differ - expected: '2001', found: '2000'