728x90 상자 부피1 [Java Examples] 상자 용량, 면적 구하는 예제 및 설명 상자 용량, 면적 구하는 예제 및 설명 포스트 난이도: HOO_Intern # Example Code public class Rectangle { private double length; private double width; // Constructor public Rectangle(double len, double w) { length = len; width = w; } // Setter for length public void setLength(double len) { length = len; } // Setter for width public void setWidth(double w) { width = w; } // Getter for length public double getLength() { .. 2024. 2. 7. 이전 1 다음 728x90