Vector-based Null Cipher
This seems like a waste of time:

std::vector&lt;std::string&gt; tokenize(const std::string &amp; str){
    std::stringstream ss(str);
    std::istream_iterator&lt;std::string&gt; begin(ss);
    std::istream_iterator&lt;std::string&gt; end;
    std::vector&lt;std::string&gt; words(begin, end);
    return words;
}


The result is used here:

std::vector&lt;std::string&gt; tokenizedPattern = tokenize(pattern);
std::transform(tokenizedPattern.begin(), tokenizedPattern.end(), 
               std::back_inserter(intTokenizedPattern), 
               [](const std::string &amp; str){ return stuff;});


You use an iterator to copy it into a vector so you can get the iterator to use in a standard algorithm. Why not just use the algorithm with the original iterator.

std::stringstream streamPattern(pattern);
std::transform(std::istream_iterator&lt;std::string&gt;{streamPattern},
               std::istream_iterator&lt;std::string&gt;{}, 
               std::back_inserter(intTokenizedPattern), 
               [](const std::string &amp; str){ return stuff;});