
1. 속성 존재 확인 객체는 여러 가지 정보를 모아둔 container 역할을 기본으로 한다. 따라서 내부에 어떤 정보가 있는지 확인할 수 있어야 한다. let obj = { id : 'trauma', test(){ console.log('Hi!'); } }; 1. 객체에 속성이 정의되지 않았다면 undefined 일 것이다. 이를 이용해서 특정 속성이 객체에 존재하는지 확인할 수 있다. 2. 우아하게 ' in ' 연산자를 이용해서 같은 일을 할 수 있다. obj.id !== undefined //true 'id' in obj; // true obj.address !== undefined //false 'address' in obj; //false 2. Object.hasOwnProperty( ) 'ha..
Programming Language/JavaScript [초급 -완결]
2022. 10. 24. 16:32
공지사항
최근에 올라온 글
최근에 달린 댓글
- Total
- Today
- Yesterday
링크
TAG
- number theory
- map
- math font
- Shell Programming
- fenwick tree
- BOJ
- 다익스트라
- bash script
- lazy propagation
- JavaScript
- python3
- dynamic programming
- 정수론
- nearest common ancestor
- Dijkstra
- C++ big number
- 백준
- Aho-Corasick
- Vim
- bash
- max flow
- stack
- persistent segment tree
- RUBY
- shell
- Reference
- script
- javascript array
- segment tree
- 세그먼트 트리
일 | 월 | 화 | 수 | 목 | 금 | 토 |
---|---|---|---|---|---|---|
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 |
글 보관함