1. Computer Science Engineering (CSE)
  2. Design and Analysis of Algorithms
  3. Which of the following methods can be us...
Q.

Which of the following methods can be used to find the sum of digits of a number?

A. recursion
B. iteration
C. greedy algorithm
D. both recursion and iteration
Answer» D. both recursion and iteration
Explanation: both recursion and iteration can be used to find the sum of digits of a number.

Discussion