Viktor97 1 year ago
commit
b2df777ae9
1 changed files with 31 additions and 0 deletions
  1. 31 0
      index.js

+ 31 - 0
index.js

@@ -0,0 +1,31 @@
+let rate = prompt("How mutch rate=stavka?")
+let days = prompt("How mutch days work?")
+let result = alert(`Вы получите ${((rate * 8) * days) * 0.8} бабосиков`)
+
+
+
+
+
+
+function input() {
+    let credentials = {
+    login: 'admin',
+    password: 'qwerty',
+};
+    let userName = prompt('User ');
+    let password = prompt('Password ');
+    userName = userName.toLowerCase();
+    password = password.toLowerCase();
+    if (credentials.login === userName && credentials.password === password) {
+        alert('Всё верно')
+        document.write ("<div style='background-color: green;'> Поздравляю  </div>")
+    }
+    else {
+            document.write ("<div style='background-color: red;'> Не верно   </div>")
+            alert('Попробуйте еще раз')
+            input()
+        }
+        
+    
+    
+}