← Quiz: Prompting for Code: all 10 questions
Quiz: Prompting for Code · Question 9 of 10
Which line is an example of stating what NOT to do?
Which line is an example of stating what NOT to do?
- A."Write a function to validate phone numbers."
- B."Return the number as +91XXXXXXXXXX."
- C."Don't add new dependencies or change the function signature."
- D."Include a few assert tests."
Answer & explanation
Correct answer: "Don't add new dependencies or change the function signature."
Constraints stop the model from making changes you do not want.
Can you get the rest right without peeking?
Take the timed Quiz: Prompting for Code quiz free. Pass it to earn XP and count towards your certificate.
Start the quiz →