nCr 캐시된 재귀함수로 구하기
Python 3.4.4 (v3.4.4:737efcadf5a6, Dec 20 2015, 20:20:57) [MSC v.1600 64 bit (AMD64)] on win32Type "copyright", "credits" or "license()" for more information.>>> def nCr(n, r):if r in (n, 0);SyntaxError: invalid syntax>>> @functools.lur_cache(maxsize=200, typed=False)def nCr(n, r):if r in (n, 0):return 1return nCr(n-1, r-1) + nCr(n-1, r) Traceback (most recent call last): File "", line 1, in @fu..