2차원 배열 선언
int[][] score = new int[4][3];
score[0][0] | score[0][1] | score[0][2] |
score[1][0] | score[1][1] | score[1][2] |
score[2][0] | score[2][1] | score[2][2] |
score[3][0] | score[3][1] | score[3][2] |
2차원 배열 초기화
int[][] arr = {
{1, 2, 3},
{4, 5, 6}
};
String class의 주요 method
substring
String str = "012345";
String tmp = str.substring(1, 4); // (int from, int to) from은 포함, to는 포함되지 않음
System.out.println(tmp); // 123
뭐라도 끄적이자...
'developer > 자바의정석(기초편)' 카테고리의 다른 글
[자바의 정석(기초편)] 연산자 (0) | 2023.03.31 |
---|---|
[자바의정석(기초편)] 3/29 개발공부일지 - 변수(1) (0) | 2023.03.29 |