fork download
  1. #include <iostream>
  2. #include <regex>
  3. #include <string>
  4. using namespace std;
  5.  
  6. int main() {
  7. const char *first = "фывфыв@NameOfElement(pupa i lupa)вфывфыв";
  8. const char *last = first + strlen(first);
  9. cmatch mr;
  10. regex rx(R"(@NameOfElement\((.*?)\))");
  11. regex_search(first, last, mr, rx);
  12. cout << mr.str(1);
  13. return 0;
  14. }
Success #stdin #stdout 0s 15336KB
stdin
Standard input is empty
stdout
pupa i lupa