optimize cases for []