Use switch instead of if/elseif