set regex

This commit is contained in:
Seth Samuel 2025-02-18 23:47:34 +00:00
parent 54d4c86867
commit 5e8a30937f

View file

@ -7,10 +7,18 @@
using namespace std; using namespace std;
int main(int argc, char const *argv[]) int main(int argc, char const *argv[])
{ {
ifstream puzzle("puzzleInput", ifstream::in); ifstream puzzle("puzzleInput", ifstream::in);
if(!puzzle){
return 1;
}
//regex
regex regexToSearch("(mul\(\d+,\d+\))")
string line; string line;
while (getline(puzzle, line)) while (getline(puzzle, line))
{ {