If you don’t use braces after your if statement, only the first line will be considered part of the if statement.
So what you really wrote, as far as the compiler knows, is:
if(Input.GetKeyDown(KeyCode.LeftSift))
speed = speed * sprint;
// END OF IF STATEMENT
isSprint = false
else if(Input.GetKeyUp(KeyCode.LeftShift))
speed = speed / sprint;
// END OF ELSE IF STATEMENT
isSprint = false;
Since the if statement ends, and there is another statement after it, the compiler has no idea what to do with that ‘else’
Instead, try: