This week's book giveaway is in the OCAJP 8 forum. We're giving away four copies of OCA Java SE 8 Programmer I Study Guide and have Edward Finegan & Robert Liguori on-line! See this thread for details.
Identifiers are only valid within the scope they are declared. You declared i within the synchronized block, it is not accessible outside of the block. There's a detailed explanation of scope in the Java Tutorial