{"id":20413,"date":"2021-09-11T15:38:23","date_gmt":"2021-09-11T10:08:23","guid":{"rendered":"https:\/\/python-programs.com\/?p=20413"},"modified":"2021-11-22T18:36:21","modified_gmt":"2021-11-22T13:06:21","slug":"python-program-to-print-multiplication-table-using-recursion","status":"publish","type":"post","link":"https:\/\/python-programs.com\/python-program-to-print-multiplication-table-using-recursion\/","title":{"rendered":"Python Program to Print Multiplication Table using Recursion"},"content":{"rendered":"

In the previous article, we have discussed Python Program to Find Sum of Even Numbers Using Recursion in a List\/Array<\/a><\/p>\n

Given a number and the task is to print the multiplication table of that number using recursion in python.<\/p>\n

Recursion:<\/strong><\/p>\n

Recursion is the process by which a function calls itself directly or indirectly, and the associated function is known as a recursive function. Certain issues can be addressed fairly easily using a recursive approach. Towers of Hanoi (TOH), Inorder \/Preorder\/Postorder Tree Traversals, DFS of Graph, and other analogous issues are examples.<\/p>\n

Examples:<\/strong><\/p>\n

Example1:<\/strong><\/p>\n

Input:<\/strong><\/p>\n

Given Number = 5<\/pre>\n

Output:<\/strong><\/p>\n

The Multiplication Table of the above given number  5 :\r\n5  X  1  =  5\r\n5  X  2  =  10\r\n5  X  3  =  15\r\n5  X  4  =  20\r\n5  X  5  =  25\r\n5  X  6  =  30\r\n5  X  7  =  35\r\n5  X  8  =  40\r\n5  X  9  =  45\r\n5  X  10  =  50<\/pre>\n

Example2:<\/strong><\/p>\n

Input:<\/strong><\/p>\n

Given Number = 2<\/pre>\n

Output:<\/strong><\/p>\n

The Multiplication Table of the above given number  2 :\r\n2  X  1  =  2\r\n2  X  2  =  4\r\n2  X  3  =  6\r\n2  X  4  =  8\r\n2  X  5  =  10\r\n2  X  6  =  12\r\n2  X  7  =  14\r\n2  X  8  =  16\r\n2  X  9  =  18\r\n2  X  10  =  20<\/pre>\n

Program to Print Multiplication Table using Recursion in Python<\/h2>\n

Below are the ways to print the multiplication table of the given number using recursion in python:<\/p>\n