GH-300 · Question #79
What practices enhance the quality of suggestions provided by GitHub Copilot? (Select three.)
The correct answer is A. Clearly defining the problem or task C. Using meaningful variable names D. Providing examples of desired output. Three practices directly improve GitHub Copilot suggestion quality. (A) Clearly defining the problem or task - through comments, function names, or chat prompts - gives Copilot precise intent to work from, reducing ambiguous or off-target completions. (C) Meaningful variable…
Question
What practices enhance the quality of suggestions provided by GitHub Copilot? (Select three.)
Options
- AClearly defining the problem or task
- BIncluding personal information in the code comments
- CUsing meaningful variable names
- DProviding examples of desired output
- EUse a .gitignore file to exclude irrelevant files
How the community answered
(16 responses)- A88% (14)
- B6% (1)
- E6% (1)
Explanation
Three practices directly improve GitHub Copilot suggestion quality. (A) Clearly defining the problem or task - through comments, function names, or chat prompts - gives Copilot precise intent to work from, reducing ambiguous or off-target completions. (C) Meaningful variable and function names provide semantic signal: Copilot infers purpose from identifiers, so descriptive names guide it toward contextually correct suggestions. (D) Providing examples of desired output in comments or docstrings acts as a specification that Copilot can match against, improving accuracy. Option B is incorrect and a bad practice - personal information in code comments is a privacy risk with no benefit to suggestion quality. Option E is incorrect: .gitignore affects version control, not Copilot's suggestion engine.
Topics
Community Discussion
No community discussion yet for this question.