const memo = {};
function fibonacciMemo(n) {
    if (n <= 1) {
        return n;
    }
    if (memo[n]) {
        return memo[n];
    }
    memo[n] = fibonacciMemo(n - 1) + fibonacciMemo(n - 2);
    return memo[n];
}
console.log(fibonacciMemo(50)); // خروجی: 12586269025