It's not printing in the array format

@Kamyanagpal hi in your display method where you are printing arr[row][col], remove ln from println, it will work!

If your query is resolved, close the doubt by marking it resolved.
Happy coding!