[Do it! 자바스크립트 기본] 06. 여러 자료를 한꺼번에 담는 객체 - 기념일 계산 프로그램 만들기 (P180)
책과 결과 값의 차이가 커서 오탈자 봤더니 "month + 1"을 빼먹었더라; (책은 재판하면서 수정놓고선 코드 수정은 안해놓음. 할말하않) 그리고 D-day는 당일부터 계산하기 때문에 -1을 해줘야 한다. (예를 들어 100일인 경우, 1을 안빼주면 101일이 된다.) 내 코드 const startValue = prompt('사귀기 시작한 날짜를 입력해주세요.', "2018-03-23"); let startDay = new Date(startValue); const toDay = new Date(); const dayMilli = 1000 * 60 * 60 * 24; const accent = document.querySelector('#accent').firstElementChild; const da..
강의/Do it!
2021. 3. 17. 22:52
공지사항
최근에 올라온 글
최근에 달린 댓글
- Total
- Today
- Yesterday
링크
TAG
- scrollTop
- javascript class
- prototype 프로퍼티
- __proto__
- 동치 연산자
- [[Prototype]]
- 불일치 연산자
- offsetTop
- 동등 연산자
- 객체의 프로퍼티
- clientHeight
- innerHeight
- constructor
- 일치 연산자
- 대괄포 표기법
- 부등 연산자
- property
- scrollHeight
- 점 표기법
- 프로퍼티
- offsetHeight
- 링크막기 #a링크막기
- clinetTop
- @font-face
- outerHeight
일 | 월 | 화 | 수 | 목 | 금 | 토 |
---|---|---|---|---|---|---|
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 |
글 보관함