Run Code
|
API
|
Code Wall
|
Misc
|
Feedback
|
Login
|
Theme
|
Privacy
|
Patreon
RegexSearch
//g++ 7.4.0 //RegexSearch //this code is created by Rezaul Hoque on February 18,2022;contact: jewelmrh@yahoo.com,Dhaka, Bangladesh //note: codes shared by Rezaul Hoque on rextester are not for sale; they are created and shared to facilitate the algorithm learning process; many like Hoque use this platform to practice programming ;Rezaul hopes his contribution helps others to fine tune their learning; #include <iostream> #include <string> #include <regex> int main () { std::string st ("\"Holistic holographic movie Hollowman was first released on a holiday in Hollywood\""); std::smatch sm; std::regex rg ("\\b([hH]ol)([^ ]*)"); std::cout << "Phrase: " << st<< std::endl; std::cout<<"Words beginning with 'Hol' or 'hol':\n"; while (std::regex_search (st,sm,rg)) { for (auto x:sm) std::cout << x << " "; std::cout << std::endl; st = sm.suffix().str(); } return 0; }
run
|
edit
|
history
|
help
0
CPP - Arrays - Ex.4
TupleCPP
Ploshtina na krug
Switch case
Dar
IceCream
find first non repeating
Depth of Bin tree
shell sort
project