Re: variable Shift might not have been initialized

You have to set Shift equal to something. If it is a field of the class, it will default to 0. If it is declared inside a method like this, you must initialize it - that is, assign it a value. Right now it doesn't hold any values at all (at line 10).