function created and used