Some exercises with functions