{"id":1115,"date":"2022-02-17T23:43:09","date_gmt":"2022-02-17T14:43:09","guid":{"rendered":"http:\/\/mylittleforest.kr\/wordpress\/?p=1115"},"modified":"2022-02-23T09:08:49","modified_gmt":"2022-02-23T00:08:49","slug":"%ec%9e%90%eb%b0%94%ec%8a%a4%ed%81%ac%eb%a6%bd%ed%8a%b8-%eb%b0%98%eb%b3%b5%eb%ac%b8","status":"publish","type":"post","link":"http:\/\/mylittleforest.kr\/wordpress\/blog\/2022\/02\/17\/1115\/","title":{"rendered":"\uc790\ubc14\uc2a4\ud06c\ub9bd\ud2b8 \ubc18\ubcf5\ubb38"},"content":{"rendered":"\n<p>\uc790\ubc14\uc2a4\ud06c\ub9bd\ud2b8 \ubc18\ubcf5\ubb38<\/p>\n\n\n\n<ul><li>While<ul><li>\uc870\uac74\uc774 \ucc38\uc778 \ub3d9\uc548 \ucf54\ub4dc\ube14\ub85d\uc744 \ubc18\ubcf5<\/li><li>\ubc18\ubcf5 \ud69f\uc218\uac00 \ubd88\uba85\ud655\ud55c \uacbd\uc6b0 \uc8fc\ub85c \uc0ac\uc6a9<\/li><\/ul><\/li><\/ul>\n\n\n\n<p>while(\uc870\uac74) {<br>\ucf54\ub4dc\ube14\ub85d<br>}<\/p>\n\n\n<div class=\"wp-block-syntaxhighlighter-code \"><pre class=\"brush: jscript; title: ; notranslate\" title=\"\">\nvar a = Math.floor(Math.random() * 10);\nvar b = Math.floor(Math.random() * 10);\nvar answer;\n\nwhile (answer != (a + b)) {\n  answer = prompt(a + '+' + b + '= ?');\n}\nconsole.log(&quot;\uc815\ub2f5\uc785\ub2c8\ub2e4.&quot;);\n<\/pre><\/div>\n\n\n<div class=\"wp-block-file\"><a href=\"http:\/\/mylittleforest.kr\/wordpress\/wp-content\/uploads\/2022\/02\/0506-while-1.html\">0506-while-1<\/a><a href=\"http:\/\/mylittleforest.kr\/wordpress\/wp-content\/uploads\/2022\/02\/0506-while-1.html\" class=\"wp-block-file__button\" download>\ub2e4\uc6b4\ub85c\ub4dc<\/a><\/div>\n\n\n\n<ul><li>For<ul><li>\ubc30\uc5f4\uc548\uc758 \uc694\uc18c\ub97c \ud558\ub098\uc529 \uaebc\ub0b4\uba70 \ubc18\ubcf5<\/li><li>\ubc30\uc5f4\uc758 \uae38\uc774\ub9cc\ud07c \ucc98\ub7fc \ubc18\ubcf5 \ud69f\uc218\uac00 \uba85\ud655\ud55c \uacbd\uc6b0 \uc8fc\ub85c \uc0ac\uc6a9<\/li><\/ul><\/li><\/ul>\n\n\n\n<p>for(var{\ubcc0\uc218}of{\ubc30\uc5f4}) {<br>\ucf54\ub4dc \ube14\ub85d<br>}<\/p>\n\n\n<div class=\"wp-block-syntaxhighlighter-code \"><pre class=\"brush: jscript; title: ; notranslate\" title=\"\">\nvar scores = &#x5B;90, 92, 84, 98, 70];\nvar sum = 0;\n\nfor (var score of scores) {\n  sum += score;\n}\nconsole.log(&quot;\ucd1d\uc810: &quot; + sum);\nconsole.log(&quot;\ud3c9\uade0: &quot; + (sum \/ scores.length));\n<\/pre><\/div>\n\n\n<div class=\"wp-block-file\"><a href=\"http:\/\/mylittleforest.kr\/wordpress\/wp-content\/uploads\/2022\/02\/0507-for-1.html\">0507-for-1<\/a><a href=\"http:\/\/mylittleforest.kr\/wordpress\/wp-content\/uploads\/2022\/02\/0507-for-1.html\" class=\"wp-block-file__button\" download>\ub2e4\uc6b4\ub85c\ub4dc<\/a><\/div>\n\n\n\n<ul><li>\uac00\uc7a5 \ud070 \uc218\ub97c \ubc18\ud658\ud558\ub294 \ud568\uc218<\/li><\/ul>\n\n\n<div class=\"wp-block-syntaxhighlighter-code \"><pre class=\"brush: jscript; title: ; notranslate\" title=\"\">\nfunction max(arr) {\n  var _max = -99999; \/\/ \uc544\uc8fc \uc791\uc740\uc218\n  for (var i of arr) {\n    if (i &gt; _max) {\n      _max = i;\n    }\n  }\n  return _max;\n}      \nconsole.log(&quot;\uac00\uc7a5 \ud070 \uc218\ub294 &quot; + max(&#x5B;5, 7, 10, 2, 8]) + &quot;\uc785\ub2c8\ub2e4.&quot;);\n<\/pre><\/div>\n\n\n<div class=\"wp-block-file\"><a href=\"http:\/\/mylittleforest.kr\/wordpress\/wp-content\/uploads\/2022\/02\/0508-max-num-1.html\">0508-max-num-1<\/a><a href=\"http:\/\/mylittleforest.kr\/wordpress\/wp-content\/uploads\/2022\/02\/0508-max-num-1.html\" class=\"wp-block-file__button\" download>\ub2e4\uc6b4\ub85c\ub4dc<\/a><\/div>\n\n\n\n<ul><li>\ubc30\uc5f4\uc744 \ud654\uba74\uc5d0 \ucd9c\ub825\ud558\uae30<\/li><\/ul>\n\n\n<div class=\"wp-block-syntaxhighlighter-code \"><pre class=\"brush: jscript; title: ; notranslate\" title=\"\">\n&lt;ul id=&quot;list&quot;&gt;&lt;\/ul&gt;\n&lt;script&gt;\n  var list = document.getElementById(&quot;list&quot;);\n  var products = &#x5B;'\ub370\uc2a4\ud06c\ud0d1', '\ubaa8\ub2c8\ud130', '\ub178\ud2b8\ubd81', '\uc2a4\ud53c\ucee4', '\ub9c8\uc6b0\uc2a4'];\n\n  var html = '';\n  for (var product of products) {\n    html += '&lt;li&gt;' + product + '&lt;\/li&gt;';\n  }\n  list.innerHTML = html;\n&lt;\/script&gt;\n<\/pre><\/div>\n\n\n<div class=\"wp-block-file\"><a href=\"http:\/\/mylittleforest.kr\/wordpress\/wp-content\/uploads\/2022\/02\/0509-print-array-1.html\">0509-print-array-1<\/a><a href=\"http:\/\/mylittleforest.kr\/wordpress\/wp-content\/uploads\/2022\/02\/0509-print-array-1.html\" class=\"wp-block-file__button\" download>\ub2e4\uc6b4\ub85c\ub4dc<\/a><\/div>\n\n\n\n<p>\uacfc\uc81c : \uc804\ub2ec \ubc1b\uc740 \ubc30\uc5f4 \uc911 \uac00\uc7a5 \ud070 \uc218\ub97c \ubc18\ud658\ud558\ub294 \uc790\ubc14\uc2a4\ud06c\ub9bd\ud2b8 \ud568\uc218\ub97c \uc791\uc131\ud574\ubcf4\uc138\uc694.<\/p>\n\n\n\n<div class=\"wp-block-file\"><a href=\"http:\/\/mylittleforest.kr\/wordpress\/wp-content\/uploads\/2022\/02\/0510-homework-1.html\">0510-homework-1<\/a><a href=\"http:\/\/mylittleforest.kr\/wordpress\/wp-content\/uploads\/2022\/02\/0510-homework-1.html\" class=\"wp-block-file__button\" download>\ub2e4\uc6b4\ub85c\ub4dc<\/a><\/div>\n","protected":false},"excerpt":{"rendered":"<p>\uc790\ubc14\uc2a4\ud06c\ub9bd\ud2b8 \ubc18\ubcf5\ubb38 While \uc870\uac74\uc774 \ucc38\uc778 \ub3d9\uc548 \ucf54\ub4dc\ube14\ub85d\uc744 \ubc18\ubcf5 \ubc18\ubcf5 \ud69f\uc218\uac00 \ubd88\uba85\ud655\ud55c \uacbd\uc6b0 \uc8fc\ub85c \uc0ac\uc6a9 while(\uc870\uac74) {\ucf54\ub4dc\ube14\ub85d} For \ubc30\uc5f4\uc548\uc758 \uc694\uc18c\ub97c \ud558\ub098\uc529 \uaebc\ub0b4\uba70 \ubc18\ubcf5 \ubc30\uc5f4\uc758 \uae38\uc774\ub9cc\ud07c \ucc98\ub7fc \ubc18\ubcf5 \ud69f\uc218\uac00 \uba85\ud655\ud55c \uacbd\uc6b0 \uc8fc\ub85c \uc0ac\uc6a9 for(var{\ubcc0\uc218}of{\ubc30\uc5f4}) {\ucf54\ub4dc \ube14\ub85d} \uac00\uc7a5 \ud070 \uc218\ub97c \ubc18\ud658\ud558\ub294 \ud568\uc218 \ubc30\uc5f4\uc744 \ud654\uba74\uc5d0 \ucd9c\ub825\ud558\uae30 \uacfc\uc81c : \uc804\ub2ec \ubc1b\uc740 \ubc30\uc5f4 \uc911 \uac00\uc7a5 \ud070 \uc218\ub97c \ubc18\ud658\ud558\ub294 \uc790\ubc14\uc2a4\ud06c\ub9bd\ud2b8 \ud568\uc218\ub97c \uc791\uc131\ud574\ubcf4\uc138\uc694.<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"inline_featured_image":false},"categories":[38],"tags":[],"_links":{"self":[{"href":"http:\/\/mylittleforest.kr\/wordpress\/wp-json\/wp\/v2\/posts\/1115"}],"collection":[{"href":"http:\/\/mylittleforest.kr\/wordpress\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"http:\/\/mylittleforest.kr\/wordpress\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"http:\/\/mylittleforest.kr\/wordpress\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"http:\/\/mylittleforest.kr\/wordpress\/wp-json\/wp\/v2\/comments?post=1115"}],"version-history":[{"count":4,"href":"http:\/\/mylittleforest.kr\/wordpress\/wp-json\/wp\/v2\/posts\/1115\/revisions"}],"predecessor-version":[{"id":1133,"href":"http:\/\/mylittleforest.kr\/wordpress\/wp-json\/wp\/v2\/posts\/1115\/revisions\/1133"}],"wp:attachment":[{"href":"http:\/\/mylittleforest.kr\/wordpress\/wp-json\/wp\/v2\/media?parent=1115"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"http:\/\/mylittleforest.kr\/wordpress\/wp-json\/wp\/v2\/categories?post=1115"},{"taxonomy":"post_tag","embeddable":true,"href":"http:\/\/mylittleforest.kr\/wordpress\/wp-json\/wp\/v2\/tags?post=1115"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}