🎙 Free live masterclass · Sun, 29 Nov, 7:00 pm IST · Java Full Stack roadmap Register free →
Skills101
← Quiz: Prompting for Code: all 10 questions

Quiz: Prompting for Code · Question 1 of 10

Which prompt is most likely to produce the code you actually need?

Which prompt is most likely to produce the code you actually need?

  1. A."write phone validation"
  2. B."make a good phone validator, thanks"
  3. C.A prompt with signature, accepted formats, output format, rejection rules and test cases
  4. D."fix my code"
Answer & explanation

Correct answer: A prompt with signature, accepted formats, output format, rejection rules and test cases

Specific inputs, outputs, rules and tests leave nothing important to guess.

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 →