c++ code to reproduce.