본문 바로가기

전체 글94

Array.prototype.some() https://developer.mozilla.org/ko/docs/Web/JavaScript/Reference/Global_Objects/Array/some Array.prototype.some() - JavaScript | MDN some() 메서드는 배열 안의 어떤 요소라도 주어진 판별 함수를 통과하는지 테스트합니다. developer.mozilla.org https://www.w3schools.com/jsref/jsref_some.asp JavaScript Array some() Method W3Schools offers free online tutorials, references and exercises in all the major languages of the web. Covering pop.. 2021. 11. 25.
Array.prototype.every() https://developer.mozilla.org/ko/docs/Web/JavaScript/Reference/Global_Objects/Array/every Array.prototype.every() - JavaScript | MDN every() 메서드는 배열 안의 모든 요소가 주어진 판별 함수를 통과하는지 테스트합니다. Boolean 값을 반환합니다. developer.mozilla.org https://www.w3schools.com/jsref/jsref_every.asp JavaScript Array.every() Method W3Schools offers free online tutorials, references and exercises in all the major languages of.. 2021. 11. 16.
Array.prototype.entries() https://developer.mozilla.org/ko/docs/Web/JavaScript/Reference/Global_Objects/Array/entries Array.prototype.entries() - JavaScript | MDN entries() 메서드는 배열의 각 인덱스에 대한 키/값 쌍을 가지는 새로운 Array Iterator 객체를 반환합니다. developer.mozilla.org https://www.w3schools.com/jsref/jsref_entries.asp JavaScript Array entries() Method W3Schools offers free online tutorials, references and exercises in all the major lan.. 2021. 11. 16.
Array.prototype.copyWithin() https://developer.mozilla.org/ko/docs/Web/JavaScript/Reference/Global_Objects/Array/copyWithin Array.prototype.copyWithin() - JavaScript | MDN copyWithin() 메서드는 배열의 일부를 얕게 복사한 뒤, 동일한 배열의 다른 위치에 덮어쓰고 그 배열을 반환합니다. 이 때, 크기(배열의 길이)를 수정하지 않고 반환합니다. developer.mozilla.org https://www.w3schools.com/jsref/jsref_copywithin.asp JavaScript Array copyWithin() Method W3Schools offers free online tutorials, re.. 2021. 11. 15.
Array.prototype.find() https://developer.mozilla.org/ko/docs/Web/JavaScript/Reference/Global_Objects/Array/find Array.prototype.find() - JavaScript | MDN find() 메서드는 주어진 판별 함수를 만족하는 첫 번째 요소의 값을 반환합니다. 그런 요소가 없다면 undefined를 반환합니다. developer.mozilla.org https://www.w3schools.com/jsref/jsref_find.asp JavaScript Array find() Method W3Schools offers free online tutorials, references and exercises in all the major languages.. 2021. 11. 12.
Array.prototype.concat() https://developer.mozilla.org/ko/docs/Web/JavaScript/Reference/Global_Objects/Array/concat Array.prototype.concat() - JavaScript | MDN concat() 메서드는 인자로 주어진 배열이나 값들을 기존 배열에 합쳐서 새 배열을 반환합니다. developer.mozilla.org https://www.w3schools.com/jsref/jsref_concat_array.asp JavaScript Array concat() Method W3Schools offers free online tutorials, references and exercises in all the major languages of the.. 2021. 11. 11.
JavaScript에서 true로 인식되는 값; 참 같은 값; Truthy https://developer.mozilla.org/ko/docs/Glossary/Truthy 참 같은 값 - 용어 사전 | MDN JavaScript에서, 참 같은 값(Truthy)인 값이란 불리언을 기대하는 문맥에서 true로 평가되는 값입니다. 따로 거짓 같은 값으로 정의된 값이 아니면 모두 참 같은 값으로 평가됩니다. (예: false, 0, -0, 0n developer.mozilla.org 비교연산에서 사용할 때는 사실 거짓 같은 값이 훨씬 중요하고, !연산으로 충분히 true/false를 바꿔서 비교할 수 있으므로 사실 참 같은 값은 별로 중요하지 않다. 하지만, 이렇게 기록하는 이유는 다음과 같은 경우를 착각하기 쉽기 때문이다. true로 인식되는 착각하기 쉬운 케이스들 if (true).. 2021. 11. 11.
JavaScript에서 false로 인식되는 값; 거짓같은 값; Falsy https://developer.mozilla.org/ko/docs/Glossary/Falsy 거짓같은 값 - 용어 사전 | MDN 거짓 같은 값(Falsy, falsey로 쓰이기도 함) 값은 불리언 문맥에서 false로 평가되는 값입니다. developer.mozilla.org 나는 Java로 프로그래밍을 시작했는데 보통 if문에서 참/거짓 연산에 대한 비교 연산을 하면 예시는 보통 다음과 같이 작성되어 있었다. boolean flag = true; if (flag == true) { System.out.println("참입니다."); } else { System.out.println("거짓입니다."); } == 연산으로 참, 거짓을 비교하는 것인데, 이 구문은 다음과 같이도 쓸 수 있다. boolea.. 2021. 11. 11.
Array.prototype.sort() https://developer.mozilla.org/ko/docs/Web/JavaScript/Reference/Global_Objects/Array/sort Array.prototype.sort() - JavaScript | MDN sort() 메서드는 배열의 요소를 적절한 위치에 정렬한 후 그 배열을 반환합니다. 정렬은 stable sort가 아닐 수 있습니다. 기본 정렬 순서는 문자열의 유니코드 코드 포인트를 따릅니다. developer.mozilla.org https://www.w3schools.com/jsref/jsref_sort.asp JavaScript Array sort() Method W3Schools offers free online tutorials, references and exe.. 2021. 11. 10.
Array.prototype.filter() https://developer.mozilla.org/ko/docs/Web/JavaScript/Reference/Global_Objects/Array/filter Array.prototype.filter() - JavaScript | MDN filter() 메서드는 주어진 함수의 테스트를 통과하는 모든 요소를 모아 새로운 배열로 반환합니다. developer.mozilla.org https://www.w3schools.com/jsref/jsref_filter.asp JavaScript Array filter() Method W3Schools offers free online tutorials, references and exercises in all the major languages of the web.. 2021. 11. 9.