Try/error function multiple choice quiz

Hi All,
I am trying to implement the try/error function into my quiz.
I want the quiz to return ‘`invalid input!’ if the user attempts question using an invalid character e…g ‘D’ when you can only choose between ‘a’ ‘b’ or ‘c’.
Any ideas as to why it is not able to process function.
I have attached screenshot showing my current code.
All advice welcome
thank you

You should really post your code formatted with markdown:

your code

The leading characters are known as backtics.

Here you go:

If you script is not 100s of lines in length, you’re going to want to post it all, otherwise we’re guessing about what we can’t see and as such, it’s that much more difficult to offer constructive advice.

Thank you Rob will try to do this.

kind regards

1 Like

No worries; you’re welcome :slightly_smiling_face:

This is also worth a read, especially if your code is way too long to be practical for others to work through.