change lambda to proc