[#78] Add C++ implementation, looks like that brute force isn't working