added example for state