Using variable vs. using number
问题 Imagine a function in those versions: int faculty(const unsigned int n) { return n == 1 ? n : n * faculty(n - 1); } int faculty(const unsigned int n) { return n == 1 ? 1 : n * faculty(n - 1); } The only difference is that I return n in the first and 1 in the second one, depending on n . The result is the same but is there any other difference you could be aware of while ignoring the significance? I know there is a high chance the compiler will make the same assembly instructions out of it,