I am implementing a simple Factorial program with following method signature.
public static long GetFactorial(int number)
{
}
What is the best practice to handle following scenarios? Shall we throw ArgumentOutOfRangeException/OverflowException exception and method will return -1?
(1) Negative input number
(2) Overflow
Go to the complete details ...