Basics
- Chrome console → option + command + j
- NaN = considered a number, but Not a Number
let year = 2023;
var은 old version.
나중에 차이점 다룰것임
Js에서는 let & const를 사용한다.
- i++ : 먼저 원래 값을 return 후 1씩 증가 / ++i : 1을 증가시킨 수 return
- Js에서는 변수의 데이터 타입을 바꾸는 것이 가능 (let a = 10; 이후 a = true 재할당 가능)
- commonly use Camelcase
String
- String indices = 변수명[num]
- String length = 변수명.length
- String methods
- string.toUpperCase()
- toLowerCase()
- trim() / 문자열 앞 혹은 뒤의 공백 제거
- 중복사용: string.trim().toUpperCase()
- String methods with arguments
- “string”.indexOf(”ing”): returns 3 (starting index) / if returns -1: not found
- .slice(beginIndex, endIndex) / if no endIndex: beginIndex to the end of the string / if Index is minus: counts from the end
- .replace(”originalString”, “newString”) / if replace all “char”, replaceAll(”char”, “newChar”)
- .repeat(10): 10번 반복
String Template Literals
let person = "You"
`I Love ${person}`;
잡소리
아 여기까지만 들으련다... 도저히 못버티겠다
안젤라 유 선생님 iOS 강의는
스스로 해내야 하는 챌린지 & 프로젝트가
매 섹션마다 있어서 재밌게 들었는데...
이분은 너무 강의 중심인듯
코드 따라치기도 한계가 있지 ㅠㅠ
졸리고 지루해서 못듣겠다
그렇다고 안젤라 웹으로 갈아타기에는
너무 업데이트가 안되어있다는 평이 많아서
섣불리 결제하고 싶지 않다...
강의는 나중에 돌아와서 다시 듣고 일단
The Odin Project로 넘어가야겠다...