Friends perform their specified actions before foes. This means that a friend's action may cause a triggered ability of a foe's permanent to trigger before that foe's action causes that permanent to leave the battlefield.