Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Recursion in CPP #24

Open
wants to merge 3 commits into
base: main
Choose a base branch
from
Open

Recursion in CPP #24

wants to merge 3 commits into from

Commits on Oct 2, 2022

  1. Create recursion.cpp

    fahadmaheri authored Oct 2, 2022
    Configuration menu
    Copy the full SHA
    7585500 View commit details
    Browse the repository at this point in the history
  2. Delete #include<iostream> using namespace std; int main() { int facto…

    …rial(int); int fact,value; cout<<"Enter any number: "; cin>>value; fact=factorial(value); cout<<"Factorial of a number is: "<<fact<<endl; return 0; } int factorial(int n) { if(n<0) return(-1);/*Wrong value*/if(n==0) return(1);/*Terminating condition* directory
    fahadmaheri authored Oct 2, 2022
    Configuration menu
    Copy the full SHA
    01bc8b3 View commit details
    Browse the repository at this point in the history
  3. Create recursion.cpp

    fahadmaheri authored Oct 2, 2022
    Configuration menu
    Copy the full SHA
    b68d1fa View commit details
    Browse the repository at this point in the history