Do I get an Integer or int after putting an int into an object array?

Posted by derrdji on Stack Overflow See other posts from Stack Overflow or by derrdji
Published on 2010-05-18T17:54:01Z Indexed on 2010/05/18 18:00 UTC
Read the original article Hit count: 215

Filed under:
|
|
|

Would (1) int a; new Object[] {a} be the same as (2) new Object[] {new Integer(a)} ? If I do the 1st one, will (new Object[]{a})[0] give me an Integer? thank you

© Stack Overflow or respective owner

Related posts about java

Related posts about object