Gennadysht 2 anni fa
parent
commit
32ba783ab3
2 ha cambiato i file con 10 aggiunte e 3 eliminazioni
  1. 3 1
      js/07/hw07_11.html
  2. 7 2
      js/12/hw12_04_check_result .html

+ 3 - 1
js/07/hw07_11.html

@@ -63,9 +63,11 @@
         };
 
         const { children: [{ children: [{ children: [spanValue] }] }] } = html;
-        children[1].children[1].children[0];
         const { children: [, { children: [, { children: [btnValue] }] }] } = html;
         const { children: [{ children: [, , , { attrs: { id } }] }] } = html;
+        console.log(spanValue);
+        console.log(id);
+        console.log(btnValue)
 
     </script>
 

+ 7 - 2
js/12/hw12_04_check_result .html

@@ -1,4 +1,4 @@
-<header>make profile timer</header>
+<header>Check result</header>
 
 <body>
     <script>
@@ -8,7 +8,7 @@
                 while (validator(result = original(...params)) == false);
                 return result;
             }
-            return wrapper
+            return wrapper;
         }
 
         //numberPrompt - это функция, которая будет запускать prompt до тех пор, пока пользователь не введет число
@@ -17,5 +17,10 @@
         //gamePrompt - это функция, которая будет запускать prompt до тех пор, пока пользователь не введет одно из слов 'камень', 'ножницы', 'бумага'
         const gamePrompt = checkResult(prompt, x => ['камень', 'ножницы', 'бумага'].includes(x.toLowerCase()))
         const turn = gamePrompt("Введите что то из списка: 'камень', 'ножницы', 'бумага'")
+       // let a = Math.random();
+        //const randomHigh = checkResult(a, x => (a >= 0.5));
+        //console.log(randomHigh);
+        
+
     </script>
 </body>