Added C++ new pattern codes