网址数据提取
#include <bits/stdc++.h> using namespace std; int main(){ string you; cin>>you; smatch s; regex b(R"((^[a-zA-Z]+)://([a-zA-Z\d\.]+)/(\w+)\?(\w+)=(\d+))"); if(regex_search(you,s,b)){ cout<<s[0]<<endl<<s[1]<<endl<<s[2]<<endl<<s[3]<<endl<<s[5]<<endl; } return 0; } // https://chat.baidu.com/search?word=1111