diff --git a/eloquentjavascript/script.js b/eloquentjavascript/script.js index 79a6fef..8878af5 100644 --- a/eloquentjavascript/script.js +++ b/eloquentjavascript/script.js @@ -2,4 +2,39 @@ let number = 0; while (number <= 12) { console.log(number); number = number + 2; -} \ No newline at end of file +} + + +let result = 1; +let counter = 0; +while (counter < 10) { + result = result * 2; + counter = counter + 1; +} +console.log(result); + +for (let number = 0; number <= 12; number = number +2){ + console.log(number); + ; +} + +for (let current = 20; ;current = current +1){ + if (current % 7 == 0){ + console.log(current); + break; + } +} + +switch (prompt("What is the weather like?")) { + case "rainy": + console.log("Remember to bring an umbrella."); + break; + case "sunny": + console.log("Dress lightly."); + case "cloudy": + console.log("Go outside."); + break; + default: + console.log("Unknown weather type!"); + break; + } diff --git a/intro_html/css.html b/intro_html/css.html index 2b07a4b..455c1ad 100644 --- a/intro_html/css.html +++ b/intro_html/css.html @@ -13,7 +13,12 @@ div.page{ height: 100vh; display: grid; - grid-template-areas: "header header """""; + grid-template-columns: 1fr 4fr; + grid-template-rows: 20px 10fr 20px; + grid-template-areas: + 'menu header' + 'menu mainContent' + 'menu footer'; ; } div.header { background-color: aquamarine; @@ -34,6 +39,18 @@ background-color: crimson; grid-area: footer; } + @media only screen and (max-width: 400px) { + div.page { + grid-template-columns: 1fr; + grid-template-rows: 20px 1fr 4fr 20px; + grid-template-areas: + 'header' + 'menu' + 'mainContent' + 'footer'; + } + + } diff --git a/intro_js/betale.html b/intro_js/betale.html new file mode 100644 index 0000000..3a93b56 --- /dev/null +++ b/intro_js/betale.html @@ -0,0 +1,49 @@ + + + +
+ + +