complete the function