check number of arguments