Bastienab
3/20/2019 - 3:01 PM

Javascripting

Javascripting

<!DOCTYPE html>
<html lang="en">

<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <meta http-equiv="X-UA-Compatible" content="ie=edge">
    <script></script>
    <title>Javascripting</title>
</head>

<body>
    <script src="javascripting.js"></script>
</body>

</html>
let age = prompt('Hey mon ami ! Tu aimes ça les patates ? (Tapez oui, non, yes ou no)');

if (age === 'oui' || age === 'yes'){
    let potatoes = '#';
    for(let i = 0; i < 7; i++){
        console.log(potatoes);
        potatoes += '#';
    }

} else if (age === 'non' || age === 'no'){
    alert(`menteur, les patates c'est la vie`);
} else {
    alert(`Je vous sens comme tiraillé`);
}