match.cpp

(plain text)
1
2
3
4
5
6
7
8
9
10
11
12
#include "match.hpp"
#include <iostream>
#include <string>

using namespace std;

int main () {
  string pattern = "???.???\\.*.???";
  string ip = "123.456.789.012";
  cout << eloi::match(ip.begin(), ip.end(), pattern.begin(), pattern.end()) << endl;
  return 0;
}