first part of switch statement inserted