R Program to Sum of Natural Numbers Using Recursion

bookmark

# Program to find the sum of natural numbers upto n using recursion

calculate_sum() 


Output

> calculate_sum(7)
[1] 28