Itertating a 2D matrix

Really helpful one!

The thing is, I am understanding the code, but having issues in writing it! The syntax is a bit changed from languages like Cpp and Python, but I guess I’ll get there. Just need some practice!