之前有寫過可以 cache 整個 component 的 React.memo function,本篇的主角是 React useMemo hook
# 前言
# 題目連結
# 解題思路
# 暴力解法
暴力解法就是跑四層 loop,如下 solution code
# can validation rule
10.14 中新增了 validation rule can,可以在欄位驗證中,使用定義的 policy 來驗證
useCallback 的用途
# 暴力解