Welcome to a number guessing game. I am thinking of a number between 1 and 100. You will be asked to guess it. I will tell you if your guess is higher or lower than the number I've chosen. You win by guessing my number!
Ready?
[[Yep, let's go.|guess]]
(set: $number to (random: 1, 100))
(goto: "intro")
(set: $guess to (num: (prompt: "What number do you guess?")))
(if: $guess is $number)[(set: $history to (history:))(set: $times to $history's ('length'))(set: $times to it - 1)Congratulations! Yes, $guess is the correct number! You win!
It took you $times guesses/turns to guess my number.](elseif: $guess < $number)[Your guess is too low.
[[Guess again.|guess]]](elseif: $guess > $number)[Your guess is too high.
[[Guess again.|guess]]]