Which one is best in programming - int or Integer? Especially whenever both are doing the same task?
I am writing an appli
As an alternative view.... perhaps you should use neither Integer nor int.
If the value is really an object with behaviour - like say an amount of money, or a distance or something, then perhaps you should be using an object with behaviour.
You can see more about this kind of thing here:
http://www.time4tea.net/wiki/display/MAIN/Microtypes
Although this may be "slower", the additional type safety will make the programming, testing and debugging of your system much easier & faster.