Open Green-JEONG opened 3 months ago
(1) if statement:
> document.querySelector('#night_day') < <input id="night_day" type="button" value="night" onclick=" if () { document.querySelector('body').style.backgroundColor = 'black'; document.querySelector('body').style.color = 'white'; } else { document.querySelector('body').style.backgroundColor = 'white'; document.querySelector('body').style.color = 'black'; } ">
> document.querySelector('#night_day').value < 'night'
It took a total of 10 minutes.
10 minutes
1. Grammar of Conditional Statements (조건문 문법)
(1) if statement:
2. Utilization of Conditional Statements (조건문 활용)