QOJ.ac
QOJ
ID | 题目 | 提交者 | 结果 | 用时 | 内存 | 语言 | 文件大小 | 提交时间 | 测评时间 |
---|---|---|---|---|---|---|---|---|---|
#706685 | #8334. Gene | lanhuo | WA | 3ms | 66112kb | C++17 | 828b | 2024-11-03 12:58:55 | 2024-11-03 12:58:57 |
Judging History
answer
#include<bits/stdc++.h>
using namespace std;
#define _ ios::sync_with_stdio(0);cin.tie(0);cout.tie(0);
#define endl '\n'
#define int long long
#define pre(i,a,b) for(int i=a;i<=b;i++)
#define rep(i,a,b) for(int i=a;i>=b;i--)
#define pii pair<int,int>
const int N = 1e6 + 10,inf = 0x3f3f3f3f3f3f3f3f;
int n,m,l,z;
string s[N],str[N];
void solve()
{
cin >> n >> m >> l >> z;
pre(i,1,n) cin >> s[i];
pre(i,1,m) cin >> str[i];
int ans = 0;
pre(i,1,n)
{
pre(j,1,m)
{
int cnt = 0,f = 1;
for(int k=l-1;k>=0;k--)
{
if(s[i][k] != str[j][k])
cnt ++ ;
if(cnt > z){
f = 0;
break;
}
}
if(f)
{
ans ++ ;
break;
}
}
}
cout << ans << endl;
}
signed main()
{
_;
int t = 1;
//cin >> t;
while(t -- )
solve();
return 0;
}
詳細信息
Test #1:
score: 0
Wrong Answer
time: 3ms
memory: 66112kb
input:
6 4 4 1 kaki kika manu nana tepu tero kaka mana teri anan
output:
5
result:
wrong answer 1st numbers differ - expected: '2', found: '5'