当前位置:网站首页>Determine whether there is an element in the string type
Determine whether there is an element in the string type
2022-07-02 05:19:00 【[email protected]】
.find() function
Exist returns the first character subscript of the searched string in the string
There is no return -1
#include<bits/stdc++.h>
using namespace std;
int main()
{
string a="caababc";
string b="abc";
int c=a.find(b);
cout<<c<<endl;
return 0;
}
版权声明
本文为[[email protected]]所创,转载请带上原文链接,感谢
https://yzsam.com/2022/02/202202151846408129.html
边栏推荐
- Paddlepaddle project source code
- 创新永不止步——nVisual网络可视化平台针对Excel导入的创新历程
- Find the subscript with and as the target from the array
- Creation and destruction of function stack frames
- Simple and practical accounting software, so that accounts can be checked
- leetcode两数相加go实现
- Online English teaching app open source platform (customized)
- go实现leetcode旋转数组
- Fabric.js 背景不受视口变换影响
- Fabric.js 自由绘制矩形
猜你喜欢
Video multiple effects production, fade in effect and border background are added at the same time
Gee dataset: chirps pentad high resolution global grid rainfall dataset
Principle and implementation of parallax effect
paddle: ValueError:quality setting only supported for ‘jpeg‘ compression
LeetCode 241. Design priorities for operational expressions (divide and conquer / mnemonic recursion / dynamic programming)
Gee series: Unit 3 raster remote sensing image band characteristics and rendering visualization
Here comes the chicken soup! Keep this quick guide for data analysts
LeetCode 1175. 质数排列(质数判断+组合数学)
Mathematical knowledge -- understanding and examples of fast power
Disable access to external entities in XML parsing
随机推荐
7.1 Résumé du concours de simulation
Online English teaching app open source platform (customized)
Johnson–Lindenstrauss Lemma(2)
Fabric. JS compact JSON
Fabric.js IText 上标和下标
Using QA band and bit mask in Google Earth engine
Latest: the list of universities and disciplines for the second round of "double first-class" construction was announced
Fabric. JS round brush
Cubemx DMA notes
Fabric.js IText 手动设置斜体
Implementation of leetcode two number addition go
Exercise notes 13 (effective letter ectopic words)
延时队列两种实现方式
There are duplicate elements in leetcode. Go implementation
Briefly introduce chown command
Storage of data
Gee: create a new feature and set corresponding attributes
国产全中文-自动化测试软件Apifox
Video multiple effects production, fade in effect and border background are added at the same time
【pyinstaller】_ get_ sysconfigdata_ name() missing 1 required positional argument: ‘check_ exists‘