GitHub Professional Certificate GitHub Copilot and AI Development Tools 1 — Questions and Answers
Question 1: What is the primary function of GitHub Copilot?
- An AI-powered code completion and suggestion tool (Correct answer)
- A code review automation service
- A repository hosting platform
- A continuous integration runner
Correct answer: An AI-powered code completion and suggestion tool
GitHub Copilot is an AI-powered coding assistant that provides real-time code completions and suggestions directly in your editor.
Question 2: Which underlying AI model powers GitHub Copilot's code suggestions?
- GPT-4
- Codex (based on OpenAI models) (Correct answer)
- BERT
- LLaMA
Correct answer: Codex (based on OpenAI models)
GitHub Copilot is powered by OpenAI Codex, a model trained on publicly available code and natural language text.
Question 3: In which file types can GitHub Copilot provide inline code suggestions?
- Only Python files
- Only JavaScript and TypeScript files
- A wide range of programming languages including Python, JS, Ruby, and more (Correct answer)
- Only files in GitHub-hosted repositories
Correct answer: A wide range of programming languages including Python, JS, Ruby, and more
GitHub Copilot supports dozens of programming languages and works in any file type where code is written.
Question 4: What is GitHub Copilot Chat primarily used for?
- Team messaging and collaboration
- Asking natural language questions about code and getting AI-generated answers (Correct answer)
- Reviewing pull requests with AI summaries
- Scheduling CI/CD pipeline runs
Correct answer: Asking natural language questions about code and getting AI-generated answers
GitHub Copilot Chat allows developers to ask questions about code in natural language and receive AI-generated explanations or suggestions.
Question 5: Which GitHub Copilot feature helps developers understand unfamiliar code by generating plain-English explanations?
- Copilot Explain (Correct answer)
- Copilot Diagnose
- Copilot Refactor
- Copilot Lint
Correct answer: Copilot Explain
The Copilot Explain feature generates natural-language descriptions of selected code blocks to help developers understand what the code does.
Question 6: What must an organization administrator configure to enable GitHub Copilot for all members of an organization?
- A GitHub Actions workflow
- A Copilot Business or Enterprise subscription and seat assignment policy (Correct answer)
- A repository-level secret
- A branch protection rule
Correct answer: A Copilot Business or Enterprise subscription and seat assignment policy
To enable Copilot for an organization, an admin must have a Copilot Business or Enterprise license and configure seat assignment for members.
What is the primary function of GitHub Copilot?