자바스크립트 연산.반복문
1. +
cosole.log("elies\'s book") // ellie's book 백슬러시를 이용해서 특수기호포함 문자를 출력
cosole.log("elies's \nbook") // ellie's ( \n 밑으로 떨어지게 해줌 ) book
// /t --> 탭을 의미함
cosole.log('1'+2); // 12 문자열에 숫자를 더하게 되면 숫자가 문자열로 변환되어 출력 2. Numeric operators
cosole.log(1 + 1) // 더하기
cosole.log(1 - 1) // 빼기
cosole.log(1 / 1) // 나누기
cosole.log(1 * 1) // 곱하가
cosole.log(1 % 1) // 나머지
cosole.log(1 ** 1) // 거듭제곱3.Increment and decrement operators
4. Assignment operators
5. comparison operators
6. Logical operators: || (or), && (and), ! (not)
|| (or)
7.Equality
8.if, else 문
9.Ternary operator
10.Switch문
11. while (반복문)
12.for문
13.break, continue
Last updated