Not really... but you have learn't that you should be very careful about creating variables within a switch statement.
Either define it prior to the switch statement, or enclose the relevant case block within { }.
The issue is to do with variable scope. The compiler thinks anything in the lines after your declaration should know about the new variable and it's initial value, but it doesn't in subsequent case blocks because it has not actually been declared.
You will get compiler warnings about this if you have them turned on (recommended).