Generate a table based on the number of rows and columns entered by the user.
Asked in frontend interviews at Google and Hotstar