Created
March 8, 2017 18:40
-
-
Save agrecascino/79a8a98814262efa1e4d6ea8b5228dda to your computer and use it in GitHub Desktop.
math
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <iostream> | |
unsigned long fgh(unsigned long n, unsigned long iter) { | |
if(!iter) { | |
return n+1; | |
} else { | |
iter -= 1; | |
unsigned long val = n; | |
for(unsigned long i = 0; i < n;i++) { | |
val = fgh(val,iter); | |
} | |
return val; | |
} | |
} | |
int main() { | |
std::cout << fgh(1,2) << std::endl; | |
return 0; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment