Added open close functionality for exercises