added helper function example