Docsity

GitHub Foundations Exam, Exams of Technology

Toggle sidebar
bg1
GitHub Foundations Exam
Question 1. What is Git primarily used for?
A) Word processing
B) Version control
C) Image editing
D) Spreadsheet calculation
Answer: B
Explanation: Git is a distributed version control system used to track
changes in source code during software development.
Question 2. Which of the following best describes GitHub?
A) An operating system
B) A web-based hosting service for Git repositories
C) A programming language
pf3
pf4
pf5
pf8
pf9
pfa
pfd
pfe
pff
pf12
pf13
pf14
pf15
pf16
pf17
pf18
pf19
pf1a
pf1b
pf1c
pf1d
pf1e
pf1f
pf20
pf21
pf22
pf23
pf24
pf25
pf26
pf27
pf28
pf29
pf2a
pf2b
pf2c
pf2d
pf2e
pf2f
pf30
pf31
pf32
pf33
pf34
pf35
pf36
pf37
pf38
pf39
pf3a
pf3b
pf3c
pf3d
pf3e
pf3f
pf40
pf41
pf42
pf43
pf44
pf45
pf46
pf47
pf48
pf49
pf4a
pf4b
pf4c
pf4d
pf4e
pf4f
pf50
pf51
pf52
pf53
pf54
pf55
pf56
pf57
pf58
pf59
pf5a
pf5b
pf5c
pf5d
pf5e
pf5f
pf60
pf61
pf62
pf63
pf64

Partial preview of the text

Download GitHub Foundations Exam and more Exams Technology in PDF only on Docsity!

Question 1. What is Git primarily used for? A) Word processing B) Version control C) Image editing D) Spreadsheet calculation Answer: B Explanation: Git is a distributed version control system used to track changes in source code during software development. Question 2. Which of the following best describes GitHub? A) An operating system B) A web-based hosting service for Git repositories C) A programming language

D) A text editor Answer: B Explanation: GitHub provides hosting for software development and version control using Git. Question 3. What is a repository in GitHub? A) A database for storing passwords B) A storage space for your project files and revision history C) A type of programming language D) A tool for compiling code Answer: B Explanation: A repository holds all the files and the revision history for a project.

C) Git is for images, GitHub is for videos D) Git is for spreadsheets, GitHub is for presentations Answer: B Explanation: Git is a version control tool; GitHub hosts Git repositories online. Question 6. Which Git object contains the actual file content? A) Tree B) Blob C) Commit D) Tag Answer: B Explanation: Blobs store the contents of files in Git.

Question 7. What does a Git commit represent? A) A backup of your entire hard drive B) A snapshot of changes in the repository C) An email notification D) A branch deletion Answer: B Explanation: A commit records a snapshot of the project at a specific point in time. Question 8. What is the purpose of a Git branch? A) To delete files B) To separate lines of development

Explanation: 'git add' stages files, preparing them to be committed. Question 10. What is a Pull Request on GitHub? A) A request to download a repository B) A request to merge your changes into another branch C) A request to delete a file D) A request to fork a repository Answer: B Explanation: Pull Requests are used to propose changes and request their review and merging. Question 11. What does 'git clone' do? A) Deletes a repository

B) Creates an exact copy of a repository C) Stages files for commit D) Updates local branches Answer: B Explanation: 'git clone' creates a local copy of a remote repository. Question 12. Which command is used to send local commits to a remote repository? A) git fetch B) git commit C) git push D) git status Answer: C

B) Tree C) Fork D) Commit Answer: C Explanation: 'Fork' is a GitHub feature, not a Git object. Question 15. What is a 'tree' object in Git? A) A list of all branches B) An object that represents directory structures C) A type of commit D) A GitHub account Answer: B Explanation: Tree objects store directories and the names of the files.

Question 16. What is a tag in Git? A) A way to mark specific commits as important B) A file extension C) A branch D) A directory Answer: A Explanation: Tags are used to mark specific points in history as important, often for releases. Question 17. What does 'git status' do? A) Pushes changes to remote B) Shows the state of the working directory and staging area

Explanation: The default branch name is now commonly 'main'. Question 19. What is GitHub Desktop? A) A cloud server B) A graphical interface to manage GitHub repositories locally C) A command-line tool D) A code editor Answer: B Explanation: GitHub Desktop is a GUI application for working with GitHub repositories. Question 20. What is the function of 'git merge'? A) Deletes a branch

B) Combines changes from different branches C) Creates a new repository D) Stages files Answer: B Explanation: 'git merge' integrates changes from one branch into another. Question 21. What is a commit message? A) A system notification B) A description of the changes made in a commit C) A branch name D) An error message Answer: B

B) Deletes a branch C) Creates a new file D) Forks a repository Answer: A Explanation: 'git pull' fetches and integrates changes from a remote repository. Question 24. What is GitHub Mobile? A) A mobile device B) An app for managing GitHub projects on mobile devices C) A type of repository D) A programming language Answer: B

Explanation: GitHub Mobile is an app for using GitHub on smartphones and tablets. Question 25. What file typically contains a project's description and instructions on GitHub? A) README.md B) LICENSE C) index.html D) config.yml Answer: A Explanation: The README.md file contains project information and instructions. Question 26. What does 'git remote' do?

Explanation: 'Published' is not a state for files in Git. Question 28. What is a 'commit hash'? A) A password for commits B) A unique identifier for each commit C) The branch name D) A repository name Answer: B Explanation: Each commit has a unique SHA-1 hash for identification. Question 29. How do you create a new branch called 'feature'? A) git branch-create feature B) git new branch feature

C) git branch feature D) git make branch feature Answer: C Explanation: 'git branch feature' creates a new branch named 'feature'. Question 30. What does 'git checkout' do? A) Leaves the repository B) Switches branches or restores working tree files C) Deletes a repository D) Stages files Answer: B Explanation: 'git checkout' switches branches or restores files.