Sure. Check out this video :)
In reply to Richard Lobb
Re: Check for a particular command in a students response.
by Levi Osborne -
This is awesome! Thank you so much exactly what I needed.
If I wanted to make sure there was a command in the answer (The opposite of the video) I would use something like this instead correct?
If I wanted to make sure there was a command in the answer (The opposite of the video) I would use something like this instead correct?
if not 'while' in __student_answer__:
print("You must use a while loop for credit!", file=sys.stderr)
sys.exit(1)
In reply to Levi Osborne
Re: Check for a particular command in a students response.
by Richard Lobb -
Yes, that's right.