조건문 (1) 썸네일형 리스트형 [20240502] 앱개발 시작하기 #4 조건문: 특정 조건을 만족했을 때에만 실행되는 코드 작성위한 문법//1. 조건문 (if문)let nums = 10;if(nums >=10){ console.log("10이상이다");}else if(num>=5){ console.log("5이상이다")}else{ console.log("5 보다 작음");}// 2. switch문 -> if문과 기능은 동일 / but 직관적let animal = "cat";switch(animal){ case "cat":{ console.log("고양이"); } default : { console.log("해당x"); }}반복문: 어떠한 동작을 반복해서 수행할 수 있도록 만들어 주는 문법 // 반복문for(let.. 이전 1 다음