QOJ.ac
QOJ
ID | 题目 | 提交者 | 结果 | 用时 | 内存 | 语言 | 文件大小 | 提交时间 | 测评时间 |
---|---|---|---|---|---|---|---|---|---|
#123687 | #6245. نوران | ushg8877 | AC ✓ | 3ms | 4152kb | C++14 | 287b | 2023-07-13 12:10:16 | 2023-07-13 12:10:19 |
Judging History
answer
#include<bits/stdc++.h>
using namespace std;
#define ll long long
#define MP make_pair
mt19937 rnd(time(0));
int main(){
ios::sync_with_stdio(false);
int n,c=0;string s,t;
cin>>n>>s>>t;
for(int i=0;i<n;i++) if(s[i]!=t[i]) c++;
cout<<((c&1)?"NO":to_string(c/2))<<endl;
}
詳細信息
Test #1:
score: 100
Accepted
time: 0ms
memory: 3548kb
input:
5 00011 11011
output:
1
result:
ok single line: '1'
Test #2:
score: 0
Accepted
time: 1ms
memory: 3520kb
input:
7 0101010 1101100
output:
NO
result:
ok single line: 'NO'
Test #3:
score: 0
Accepted
time: 3ms
memory: 4152kb
input:
344014 01000100100000000000010000010011011100111100000101001101000000110000101100011010011001011100101111000101101010111101001010111000011000001011011101011100110010001101000110110001111011001001010001001100011000100001110001000111111111011101111111000011011000010110101100111101111110010001000010110...
output:
86254
result:
ok single line: '86254'
Test #4:
score: 0
Accepted
time: 2ms
memory: 3632kb
input:
84004 110101100011001100100100110110110101000111110110010011101010000111011011101100100100101110010001100010111100011111011100101101110010111110110000101000111000000101011001110001100111110011010111011000110110110011001101010100100100011101010100101000011001110111110000010010101000010110101011111010...
output:
20970
result:
ok single line: '20970'
Test #5:
score: 0
Accepted
time: 1ms
memory: 3524kb
input:
400 10100100110110111111101100001001100010011111110100111111110111000111101011000011101010111110111011010011011011111100110000100010101001111100110110111110011011000000110001010110000111100010010111110111000011000011011001011101011010001100010100111011010000001111010111110000000000101000011101011011...
output:
NO
result:
ok single line: 'NO'
Test #6:
score: 0
Accepted
time: 1ms
memory: 3516kb
input:
111 010110101111001100010011010010101011000110100110110100110001011100000110000000011100000010101110111100010010010 110101000010000011011000100011000101000010111001000001010001001101100000100000011111101101011100010100111110000
output:
27
result:
ok single line: '27'
Test #7:
score: 0
Accepted
time: 1ms
memory: 3516kb
input:
292 1111000110010100101010110111111001010111010110110110111001011011011000010100100111000000110100100111101110100010100001011111100010110110101110110111000110011011100100111000010110011001011101101101101010000110111001000011100000100110010100001010010010001000100011100100000100010101100001000011 011...
output:
NO
result:
ok single line: 'NO'
Test #8:
score: 0
Accepted
time: 1ms
memory: 3504kb
input:
16 0110101110101100 0100110100000110
output:
NO
result:
ok single line: 'NO'
Test #9:
score: 0
Accepted
time: 1ms
memory: 3512kb
input:
158 11101111010111101111011101111000010001011100011100101100100101010110001100110011000100101101101100010011111010000001101011101110110000000011110100011010111101 00000001101101111001000101111111100000001001110001110110101110111100001101111011000000001010100101111001100000000111101111010100011100011...
output:
38
result:
ok single line: '38'
Test #10:
score: 0
Accepted
time: 1ms
memory: 3492kb
input:
18 111000111011010001 010101110101011010
output:
5
result:
ok single line: '5'