Recursion/Programs/sum_n.cpp
//iterative function to find sum of n natural numbers
iterative function to find sum of n natural numbers
iterative function to find sum of n natural numbers
int i_sum(int n)
{
    int sum=0;
    for(int i=1;i<=n;i++)
    {
        sum = sum+i;
    }
    return sum;
}
int i_sum ( int n ) { int sum = 0 ; for ( int i = 1 ; i <= n ; i ++ ) { sum = sum + i ; } return sum ; }
iterative function to find sum of n natural numbers
iterative function to find sum of n natural numbers
//cout<<sum;