首页
DreamJudge
院校信息
考研初试
考研复试
保研专区
讨论区
兑换中心
登录
注册
上岸
以下题解仅供学习参考使用。
抄袭、复制题解,以达到刷AC率/AC数量或其他目的的行为,在N诺是严格禁止的。
N诺非常重视学术诚信。此类行为将会导致您成为作弊者。具体细则请查看N诺社区规则。
JERRY466
2026年3月3日 19:04
查找 - 北邮 题解:
P1387
回复 0
|
赞 1
|
浏览 35
#include<bits/stdc++.h> using namespace std; int main(){ string s; int n; while(cin>>s>>n){ for(int j=0;j<n;j++){ string t;//命令字符串  ...
bro
2026年2月12日 15:37
查找 - 北邮 题解:c++
P1387
回复 0
|
赞 10
|
浏览 172
#include <bits/stdc++.h> using namespace std; int main(){ string str; int n ; while(cin >> str >> n){ string s; while(n--){ cin &...
牧濑
2026年2月10日 15:33
查找 - 北邮 题解:
P1387
回复 0
|
赞 4
|
浏览 126
#include <iostream> #include <string> #include <vector> #include <algorithm> using namespace std; int main(){ string str; while(cin>>str){ int n; cin>>n; vector<s...
mlx
2026年2月9日 16:02
查找 - 北邮 题解:
P1387
回复 0
|
赞 0
|
浏览 111
#include<iostream> #include<algorithm> using namespace std; string str; int n; int main() { string op; while(cin>>str) { cin>>n; for(int i=0;i<n;i++) { cin>>op; if(op[0]=='0') { int index=op[1]-'0'; int len=op[2]-'0...
kawhileo
2026年2月4日 11:48
查找 - 北邮 题解:string
P1387
回复 0
|
赞 3
|
浏览 192
#include<bits/stdc++.h> using namespace std; int main(){//动态查找 string s,m; int n; while(cin>>s){//多组输入 cin>>n; while(n>0){ ...
SpontySoul
2026年2月1日 22:35
查找 - 北邮 题解:依旧<string.h>
P1387
回复 0
|
赞 3
|
浏览 185
#include <bits/stdc++.h> using namespace std; int main() { string s; int n; while(cin >> s){ cin >> n; vector<string> order(n); for(int i = 0; i < n; i++) { cin >> order[i]; int op...
jiuzhu123
2026年1月30日 16:11
查找 - 北邮 题解:
P1387
回复 0
|
赞 0
|
浏览 194
怎么没读懂题目意思啊
爱学习的小妞
2025年3月18日 16:48
查找 - 北邮 题解:WA50%求解
P1387
回复 2
|
赞 11
|
浏览 1.6k
#include <bits/stdc++.h> #include <algorithm> using namespace std; void oper_0(string &a,int x,int y) { for(int i=x;i<=(x+y-1)/2;i++) { char temp=a[i]; a[i]=a[x+y-i-1]; &n...
zxjrheaven
2025年3月14日 23:23
查找 - 北邮 题解:暴力,拼尽全力终于战胜
P1387
回复 0
|
赞 2
|
浏览 1.1k
#include <bits/stdc++.h> using namespace std; string fanzhuan(string str,char a,char b,int c) { char str2[c]={0}; int t=(a-'0')+(b-'0')-1; for(int i=a-'0';i<a-'0'+b-'0';i++) &n...
seventeen
2025年3月13日 19:18
查找 - 北邮 题解:
P1387
回复 0
|
赞 10
|
浏览 1.0k
#include<iostream> #include<string> #include<algorithm> #include<vector> #include<map> #include<queue> using namespace std; int main() { string s; cin >> s; int n; &nbs...
1
2
3
题目
查找 - 北邮
题解数量
24
发布题解
在线答疑
热门题解
1
字符串函数的使用:reverse() 翻转;substr()获取子串;replace()进行字符串替换
2
查找 - 北邮 题解:求大佬看看哪儿有问题,始终只有33%的通过率
3
比较笨
4
C++,偷懒简洁高效版,直接用reverse()、replace()函数一步搞定字符串的翻转和替换
5
查找 - 北邮 题解:替换部分求问
6
查找 - 北邮 题解:WA50%求解
7
查找 - 北邮 题解:c++
8
查找 - 北邮 题解:
9
查找 - 北邮 题解:过了,替换长度可能不一样,用到了string的erase函数和insert函数
10
查找 - 北邮 题解:通过率只有33%,求佬帮忙看一下,是不是思路有问题