Update beautifulMatrix.cpp