上海交通大学交大密西根 ·联合学院一 81 UM-SJTU Joint Institute University of Michigan Shanghal Jiao Tong University Recursion Paradigm In general,the body of a recursive function has the following form: if(test for simple case) { Compute a simple solution without recursion. } else { Break the problem down into subproblems of the same form. Solve each of the subproblems by calling this function recursively. Reassemble the solutions to the subproblems into a solution for the whole.Recursion Paradigm Recursion Paradigm • In general, the body of a recursive function has the following form: if (test for simple case) { Compute a simple solution without recursion. } else { Break the problem down into subproblems of the same form. Solve each of the subproblems by calling this function recursively. Reassemble the solutions to the subproblems into a solution for the whole. }