Which of the following methods used to find the sum of first n natural numbers has the least time complexity?
(a) Recursion
(b) Iteration
(c) Binomial coefficient
(d) All have equal time complexity
The question was asked by my school principal while I was bunking the class.
Asked question is from Sum of n Natural Numbers using Recursion topic in chapter Recursion of Data Structures & Algorithms II