/**
 * Calculates the factorial of a number.
 * @param {number} n - The number to calculate the factorial of.
 * @returns The factorial of the given number, or NaN if the number is negative.
 * @example
 * factorial(5); // 120
 */
export declare function factorial(n: number): number;
