switch-statements for flow of control