일 | 월 | 화 | 수 | 목 | 금 | 토 |
---|---|---|---|---|---|---|
1 | 2 | 3 | 4 | 5 | 6 | |
7 | 8 | 9 | 10 | 11 | 12 | 13 |
14 | 15 | 16 | 17 | 18 | 19 | 20 |
21 | 22 | 23 | 24 | 25 | 26 | 27 |
28 | 29 | 30 |
- count_program
- switch-case
- 배열 array
- 업다운 게임
- IF else
- 할당 연산자
- 변수
- 접근제한자
- 컬렉션프레임워크
- 형변환 연산자
- var 변수
- 삼항(조건) 연산자
- 논리 연산자
- Math 함수
- 관계 연산자
- 반복문
- Scanner
- 변수 기본형
- 표 구현
- Do while
- Style Sheet
- 가위바위보 게임
- 객체 배열
- 간단한 연산
- 유효성 검사
- 문자열 비교
- SQLIntegrityConstraintViolationException
- DropDown
- color code
- decimalformat
- Today
- Total
무룩 공부방

# 문제 고정크기의 객체배열을 활용해 만들었던 성적처리 프로그램을 컬렉션프레임워크-List-ArrayList를 이용해 코드를 수정 package java02_intermediate.ArrayListScore; public class Student { private int num; private String name; private int kor; private int eng; private int mat; private int tot; private double avg; private String hak; private int rank; public int getNum() { return num; } public void setNum(int num) { this.num = num; } public Str..
* 배열의 단점 : 고정크기이며 삽입, 삭제 처리가 어렵다. # 컬렉션 프레임워크(Collection Framework) 객체들의 저장소 객체의 개수에 따라 크기 조절 다양한 객체들의 삽입, 삭제, 검색등의 작업을 쉽게 처리 가능 # 제네릭 특정 타입만 다루지 않고 여러 종류의 타입(객체)을 다룰 수 있도록 일반화된 타입 매개변수 제네릭 타입의 매개변수로 사용되는 식별자 , , (Element) 컬렉션 요소의 타입 (Key) Map에서 Key의 타입 (Value) Map에서 Value의 타입 EX) ArrayList - E타입 요소를 저장하는 ArrayList를 선언 ArrayList - Integer 타입 요소를 저장하는 ArrayList를 선언 HashMap - K타입의 Key와 V타입의 값으로 구성..

package java02_intermediate; class Calc { int n; static int m; void f1(int x) { n = x; } void f2(int x) { m = x; } static void s1(int s) { //n = x; // 컴파일 오류 static 메서드는 non-static 멤버변수 사용 불가 } static void s2(int x) { //f1(3); // static 메서드는 non-static 메서드 사용 불가 } public static int abs(int a) { return a > 0 ? a : -a; } public static int max(int a, int b) { return (a > b ? a : b); } public static..

package java02_intermediate; public class Java13 extends Object { private String name; private String age; private int score; public String getName() { return name; } public void setName(String name) { this.name = name; } public String getAge() { return age; } public void setAge(String age) { this.age = age; } public int getScore() { return score; } public void setScore(int score) { this.score =..