| Run ID | 作者 | 问题 | 语言 | 测评结果 | Time | Memory | 代码长度 | 提交时间 | 
|---|---|---|---|---|---|---|---|---|
| 135091 | 徐英杰 | 字符串包含判断 | C++ | Wrong Answer | 1 MS | 276 KB | 1478 | 2025-11-02 15:22:55 | 
#include <iostream> #include<string> using namespace std; int jc(int n) { //递归出口 if (n == 0 || n == 1) { return 1; } //n的阶乘=n*(n-1的阶乘) return n * jc(n-1); } int gcd(int a,int b) { if (a%b == 0) { return b; } return gcd(b,a%b); } long long x_n(int x,int n) { if ( n == 0) { return 1; } if (x == 0) { return 0; } if (n == 1) { return x; } return x * x_n(x,n-1); } void OJ1490_baoli(int k) { for (int i = 1;i <= 2*k;i++) { for (int j = 0;j <= k*(k+1);j++) { if (i <= j) { if (k*(i+j) == i*j) { cout<<"1/"<<k<<" = "<<"1/"<<i<<" + "<<"1/"<<j<<endl;; } } } } } void OJ1490(int k) { for (int x = k+1;x <= 2*k;x++) { int a = k*x; int b = x-k; if (a % b == 0) { cout<<"1/"<<k<<" = "<<"1/"<<x<<" + "<<"1/"<<a/b<<endl;; } } } bool OJ1467(string a,string b) { for (int i = 0;i <= a.size()-b.size();i++) { if (b[0] == a[i]) { for (int j = 0;j < b.size();j++) { if (b[j] != a[i+j]) { break; } } return true; } } return false; } int main() { string a,b; cin>>a>>b; cout<<(OJ1467(a,b) ? "yes":"no"); return 0; }
------Input------
fdcdgtofze dgtf
------Answer-----
no
------Your output-----
yes