Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <!DOCTYPE html>
- <html>
- <head>
- <meta charset="utf-8" />
- <title>Do you want potatoes?</title>
- </head>
- <body>
- <h1>Quête Javascripting</h1>
- <script>
- var potatoe = "#";
- function potatoes(){
- for (var i = 0; i <= 7; i++) {
- console.log(potatoe);
- potatoe = potatoe + "#";
- }
- }
- var result = prompt("Hey Polo! Tu aimes ça les patates ?! \n (Oui? Non? Autre?)");
- if (result.toLowerCase() === "oui"){
- potatoes();
- }
- else if (result.toLowerCase() === "non"){
- alert("Tu ne sais pas ce que tu rate !!!");
- }
- else{
- alert("Je te sens comme tiraillé... Faut faire un choix !");
- }
- </script>
- </body>
- </html>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement