integer

Java_int와 Integer의 차이
▶ Integer와 int의 차이를 알기 위해서는 우선 Java서는 원시타입 (Primitive Type), 래퍼 클래스 (Wrapper Class)가 있다. 원시타입과 래퍼클래스는 위처럼 나뉘어진다. 원시 타입으로는 byte, short, int, long, float, double, boolean, char 이 있고, 래퍼 클래스로는 Byte, Short, Integer, Long, Float, Double, Boolean, Character 가 있다. ▶ Primitive Type과 Wrapper Class는 무슨 차이가 있는걸까? Wrapper Class는 Primitive Type을 객체화한 것이다. ( wrap == 포장 ) public class Main { public static void..