일 | 월 | 화 | 수 | 목 | 금 | 토 |
---|---|---|---|---|---|---|
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 |
31 |
- 테이블
- 인텔리제이
- Files
- json
- 이클립스
- ArrayList
- js
- Button
- 이탈리아
- date
- Maven
- windows
- Eclipse
- 자바스크립트
- CMD
- input
- Visual Studio Code
- html
- CSS
- javascript
- string
- Array
- vscode
- Java
- list
- IntelliJ
- 자바
- table
- 배열
- 문자열
- Today
- Total
목록string (34)
어제 오늘 내일
Javascript의 문자열에서 첫번째 글자를 삭제하는 방법입니다. 여기서는 substr(), substring(), slice() 함수를 사용하여 첫번째 글자를 삭제하는 방법을 알아보도록 하겠습니다. 문자열의 첫글자 삭제하기 See the Pen 문자열 by anna (@hianna) on CodePen. substr(), substring(), slice() 이 세 개의 함수 모두 원래의 사용 방법은 조금씩 다릅니다. substr() string.substr(start, length) substr() 함수는 파라미터로 전달된 시작 index(start)부터 길이(length)만큼 문자열을 잘라서 리턴합니다. length를 입력하지 않으면 시작 index부터 문자열의 끝까지를 리턴합니다. substri..
이번에는 앞에서 소개한 32bit로 인코딩된 문자를Java 코드를 통해 확인해 보도록 하겠다.([JavaAPI] String 클래스 메소드와 예제(2) - Unicode 처리(1) 참조) public boolean equals(Object anObject) Returns the length of this string. The length is equal to the number of Unicode code units in the string.String 클래스의 length() 메소드는 string의 길이를 리턴한다. 정확히는 unicode code unit의 숫자를 리턴한다. int ch32[] = {0x1F0A1}; // 🂡 String st32 = new String(ch32, 0, 1); int ..
java.lang.String 클래스의 메소드 public int length() Returns the length of this string. The length is equal to the number of Unicode code units in the string. String 클래스의 length() 메소드는 말 그대로 String의 길이를 리턴하는 메소드이다.그런데...Unicode code units? 이건 뭐지?이걸 알기 위해서는 먼저 Java에서 Unicode를 어떻게 표현하는지 알아야 한다. Unicode / Code Point유니코드(Unicode)는 전 세계의 모든 문자를 컴퓨터에서 일관되게 표현하고 다룰 수 있도록 설계된 산업 표준이다.- Wikipedia(https://ko.wik..
Java에서 많이 사용되는 클래스의 메소드를 예제를 포함하여 정리해 보려고 한다. (Java 8 기준) java.lang.String 생성자 String() String(byte[] bytes) String(byte[] bytes, Charset charset) String(byte[] bytes, int offset, int length) String(byte[] bytes, int offset, int length, Charset charset) String(byte[] bytes, int offset, int length, String charsetName) String(byte[] bytes, String charsetName) String(char[] value) String(char[] val..