problemscpp
A collection of my answers to algorithm problems in c++.
静态 Public 成员函数 | 所有成员列表
acwing::acwing762类 参考

AcWing 762. 字符串匹配 更多...

#include <acwing.h>

静态 Public 成员函数

static int main (istream &cin, ostream &cout)
 

详细描述

AcWing 762. 字符串匹配

在文件 acwing.h1123 行定义.

成员函数说明

◆ main()

int acwing::acwing762::main ( istream &  cin,
ostream &  cout 
)
static

在文件 acwing.cpp3609 行定义.

3609 {
3610 double k;
3611 string a;
3612 string b;
3613 int match = 0;
3614 cin >> k >> a >> b;
3615 for(int i = 0; i < a.length(); i++) {
3616 if(a[i] == b[i]) {
3617 match++;
3618 }
3619 }
3620 cout << (match >= k * a.length() ? "yes" : "no");
3621 return 0;
3622 }

被这些函数引用 acwing::TEST().


该类的文档由以下文件生成: