add  higher-order function