title: How to print a row wise sorted matrix in C++
body: <p>I am given a 2D array of numbers whose each row is sorted individually. I need to print the whole matrix in sorted order(ascending). Can anyone tell how to do it efficiently and its time complexity. If you can code,please paste your C++ code.</p>