online compiler and debugger for c/c++

code. compile. run. debug. share.
Source Code   
Language
#include <string> #include <regex> #include <iostream> int main() { std::string line{"my name is my name and not my name mysometext myto"}; //this is the original line std::cout << line << std::endl; std::string replaceThis,replaceWith; std::cout<<"Enter the word that you want to replace in the above: "; std::getline(std::cin, replaceThis); std::cout<<"Enter the word that you want to replace it with: "; std::getline(std::cin, replaceWith); std::regex pattern("\\b" + replaceThis + "\\b"); std::string replacedLine = std::regex_replace(line, pattern, replaceWith); std::cout<<replacedLine<<std::endl; }

Compiling Program...

Command line arguments:
Standard Input: Interactive Console Text
×

                

                

Program is not being debugged. Click "Debug" button to start program in debug mode.

#FunctionFile:Line
VariableValue
RegisterValue
ExpressionValue