P051T1V3 commited on
Commit
2ccd203
1 Parent(s): 13071c0

fix: Ch2 Q1 answer check

Browse files

The question suggests that the word count of the response should be evaluated but the character count is checked instead.

Files changed (1) hide show
  1. app.py +1 -1
app.py CHANGED
@@ -350,7 +350,7 @@ challenges = [
350
  {
351
  "title": "Question 1. Length of Prime",
352
  "description": "Craft a question with word count of a prime number, that prompts a response whose word count is exactly its succeeding prime number.",
353
- "validator": lambda response, input: is_prime(len(input.split())) and len(response) == next_prime(len(input.split()))
354
  },
355
  {
356
  "title": "Question 2. Larger as we speak",
 
350
  {
351
  "title": "Question 1. Length of Prime",
352
  "description": "Craft a question with word count of a prime number, that prompts a response whose word count is exactly its succeeding prime number.",
353
+ "validator": lambda response, input: is_prime(len(input.split())) and len(response.split()) == next_prime(len(input.split()))
354
  },
355
  {
356
  "title": "Question 2. Larger as we speak",