1131:基因相关性

模拟过程,字符串操作

#include<bits/stdc++.h>
using namespace std;
int main(){
	char a[550],b[550];
	double d;
	cin>>d>>a>>b;
	int s=0;
	for(int i=0;i<strlen(b);i++){
		if(a[i]==b[i]) s++;
	}
	double d2=1.0*s/strlen(b);
	if(d2>=d) cout<<"yes";
	else cout<<"no";
	return 0;
}