java↗7-9. 메서드호출
메서드이름(값1,값2,...); print99danAll(); // void print99danAll()을 호출 (void - 반환타입, 출력이 없다 = 내가 작업을 수행하고 줄 것이 없다) int result = add(3, 5); // int add(int x ,int y)를 호출하고, 결과를 result에 저장 (int - 출력, int x, int y - 입력) class Ex6_4 { public static void main(String args[]) { MyMath mm = new MyMath(); long result1 = mm.add(5L, 3L); long result2 = mm.subtract(5L, 3L); long result3 = mm.multiply(5L, 3L); double..
2024.03.27