This week's book giveaway is in the OO, Patterns, UML and Refactoring forum. We're giving away four copies of Refactoring for Software Design Smells: Managing Technical Debt and have Girish Suryanarayana, Ganesh Samarthyam & Tushar Sharma on-line! See this thread for details.
It does. Your problem is that your ArrayList is a raw ArrayList; the compiler doesn't know that it contains only Integer objects. If you change the declaration to the compiler knows that this list will contain only Integer objects, and therefore get(1) will return an Integer. If you are absolutely certain that it does not return null you can use auto unboxing to turn that back into an int:
As I said, only do this if you are certain that the Integer is not null. If it is, the auto unboxing will throw a NullPointerException.
1) it is better to declare as interfaces or abstract classes. If you don't know why search around in Beginning Java and Java in General for the answer.