Explain the difference between useMemo and useCallback and when you would use each in a high-performance application.