Azure Developer League: DevOps & GitHub Challenge

Azure Developer League: DevOps & GitHub Challenge


  • Which of the following scenarios is a common use case for a version control system?-Making experimental changes to your project in an isolated branch
  • What is another name for a version control system?-

    Software configuration management (SCM) system
  • What’s the difference between Git and GitHub?-Git lets you work with one or more local branches and push changes to a remote repository. GitHub acts as the remote repository, which is accessed through a website or command-line tools.
  • What Git command gives information about how to use Git?-git help
  • What Git commands can be used to correct mistakes?-git reset and git revert
  • What is the primary advantage of the distributed nature of Git?-Multiple remote contributors can work together on a project without fear of overwriting each other's work. Contributors can check changes from another contributor before merging them with their own.
  • When a Git user copies a repository, what term describes the reference that Git sets up for the original repository?-

    remote
  • What Git command makes a copy of an existing repository?-git clone <repo-path>
  • What Git command can be used to save current changes, but without using a pull request?-git stash
  • suppose you have a project that has 10 files in your local working branch of the repo. You recently updated 3 of the files: toc.ymlintro.txt, and exercise.json. Now, you want to create a pull request for only the changes to the JSON file. What set of Git commands should you use to create the pull request for only those changes?-git add exercise.json
    git commit -m "my changes for the exercise"
    git push origin <working-branch>


  • Which of the following statements is true about branches in Git?-Work done on a branch doesn't interfere with work in other branches.

  • Which of the following Git commands creates a new branch, and then changes your working location to the new branch?-git branch my-new-branch
    git checkout my-new-branch

  • Suppose you try to merge changes from your local branch into the project repo, but Git returns a merge conflict error. What command can you use to restore the default (main) branch to its correct state?-git merge --abort

  • Which of the following samples is an accurate view of what Git might show for a merge conflict between the my-penguins branch and the main branch?-
<head><body> <img class="cat" src="images/panda.jpg"> <img class="cat" src="images/peacock.jpg"> <<<<<<< my-penguins <img class="cat" src="images/penguin.jpg"> ======= <img class="cat" src="images/platypus.jpg"> <img class="cat" src="images/pony.jpg"> >>>>>>> main <footer>Copyright 2021 - Perfect Pets</footer> </body></head>
  • What is the best way to report a bug to a GitHub project?-Search for the bug in the project's existing issues and create a new one if it hasn't been reported yet.

  • Suppose you have created a bug fix on a new branch and want it to become part of the next production build generated from the main branch. What should you do next?-Create a pull request to merge your new branch into the main branch.
  • It is recommended that you create commits on a branch separate from main, and there are plenty of good reasons why. What is not a good reason?-GitHub doesn't allow you to commit directly to the main branch.
  • Suppose you'd like to work with a project on GitHub but you don't have write access to the project. What can you do to contribute?-Fork the project's repository to your GitHub account, clone the forked repository to your local machine, push changes to your repository, and submit a pull request to the target (upstream) repository.
  • You want to grant a user the permissions required to add and remove organization members to a team. Which permission would you need to grant that user?-

    Team maintainer
  • As an organization owner, you want to ensure that everyone who is logged into your corporate network can access the GitHub website without requiring a second login. Which technology will you enable to accomplish this?-Single Sign-On
  • What is the appropriate repository permission level for contributors who will actively push changes to your repository?-write
  • You plan on using GitHub Actions to build, test, and deliver your cross-platform code. Which of the following platforms will be the most expensive to use?-macOS
  • When would you decide to upgrade to the GitHub Enterprise product?-Because you want to centrally manage users and repositories across multiple organizations.
  • What is the purpose of a team?-A team is intended to reflect a company or group's structure, and is used to provide cascading access permissions and make it easy to notify all team members via mentions
  • Which of the following choices is not a good reason to protect a branch?-The branch contains sensitive information that you don't want other repository participants to be able to see.
  • Suppose your team repository contains several long-lived branches, including masterrelease-v1.0, and release-v2.0. Which of the following Git commands best enables you to apply specific commits from master into release-v1.0 to apply hotfixes to the legacy version of the codebase?-git cherry-pick
  • Your project team has reached a major milestone and wants everyone to install the latest version of your app. Which option is the best way to let interested users know?-Create a release on GitHub.
  • Artifacts from a GitHub Actions workflow can be saved with what action?-The actions/upload-artifacts action
  • What is one way that GitHub Actions workflows can NOT be used?-To upload a new secret to GitHub Secrets.
  • Which action would you use to access a repository's code from the virtual machine provided by GitHub Actions?-actions/checkout
  • How many builds will the following matrix produce? os: [ubuntu-latest, windows-2016] node-version: [8.x, 10.x, 12.x]-6
  • What is not a good reason to create a pull request?-Your branch cannot be merged into master due to upstream changes made since you created it. Creating a pull request will let the other contributor know they need to pull their changes out so you can put yours in.
  • How can you ensure that pull requests for a given area of the repository are not merged unless certain users or teams have approved?-Use a CODEOWNERS file and enable required reviews.
  • You have been requested to review a pull request. As you read through it, you notice several minor coding errors and typos. How should you handle the review?-Start a review and fix obvious typos inline. Add comments in places that require further discussion or offer educational value. Complete the review with changes requested.
  • Which of the following statements about merges is false?-When a merge completes successfully, it ensures that your changes didn't break the build.
  • Why are merge conflicts bad?-This is a trick question. Merge conflicts aren't bad; they're an inevitable part of distributed version control.
  • What is the best way to avoid most complex merge conflicts?-Regularly pull updates your branch.
  •  

    How does GitHub's top-level search bar differ from the search options available on repository tabs?-

    The top-level search bar supports searching everything across all of GitHub, whereas the repository tab searches are scoped to cover specific types in the current repository.
  • What does git blame do?-It displays the commit history of the file.
  • Suppose a bug issue is reported on your project, and you know which pull request introduced the problem. Which of the following options is not a cross-linking best practice?-Do not create cross-links when the root cause of the issue is already known.
  • Which of the following scenarios is not a good candidate to be built as a GitHub App?-An app that allows a user to approve a pull request from a custom tool.
  • When should you build an OAuth App instead of a GitHub App?-When your app needs to operate on behalf of a specific user.
  • Which of the following choices is not a benefit of using webhooks over polling?-Webhooks have better network accessibility than polling.
  • What is GitHub Script?-A workflow action that enables GitHub API access from GitHub Actions.
  • What is the difference between GitHub Script and GitHub Actions?-GitHub Actions is a workflow engine that automates the execution of actions. GitHub Script is one of the actions available for use in a workflow.
  • Why would someone use the following YAML in a GitHub Script action: if: contains(github.event.issue.labels.*.name, 'bug')?-To ensure that the script only runs when the target issue has been labeled as a bug.
  • How do you grant your GitHub repository access to Azure?-Manage credentials using GitHub Secrets and use that secret name in the workflow
  • What can trigger a workflow for deploying to Microsoft Azure?-Any event, just like any other Action
  • How do you make sure that your Azure credentials are not stored in plain text in your repository?-Use GitHub Secrets to securely store your Azure credentials.
  • Which type of version control enables you to work from your own copy of the main repository?-Distributed version control
  • A Git branch is used to:-Make changes and experiment with the codebase without affecting other developers' work.
  • The git pull command:-Downloads and merges the latest changes from the remote repository into your local repository.
  • Which of the following is not an important consideration for migrating a source repository to GitHub?-Does GitHub support the programming language your project uses?
  • Why is a .gitignore file important to your repository?-It helps you enforce policy around which files are not to be tracked by version control.
  • Which of the following is not a valid way to migrate a project to GitHub?-Email a password protected zip of your project to GitHub support along with instructions for the repository's creation. Be sure to include the zip password in the same email.
  • What kind of files are best stored in GitHub?-Text files, like source code.
  • Why is a .gitignore file important to your repository?-It helps you enforce policy around which files are not to be tracked by version control.
  • Which of the following is not a valid way to upload new project files to GitHub?-Email a password protected zip of your project to GitHub support along with instructions for the repository's creation. Be sure to include the zip password in the same email.
  • Which of the following choices best describes the relationship between open source and InnerSource programs?-InnerSource programs are fundamentally the same as open source programs, except that their access is limited to people within their organization.
  • Suppose your team has been receiving some low-quality bug reports without enough information to properly diagnose. Which of the following choices is the best way to address the issue?-Add an ISSUE_TEMPLATE.md file that includes fields for reproduction steps, system properties, and instructions for generating and including important logs.
  • Suppose your team has been tracking data of all kinds since your InnerSource program went live three months ago. Which of the following metrics indicates your program is a great success?-A dramatic rise in pull requests that address bugs in your software.
  • Which of the following Markdown snippets would produce this text: Hello, world!?-*Hello, **world**!*
  • How do you print certain characters, like asterisks (*) and underscores (_), literally on your output?-Escape them with a backslash, like \* or \_.
  • Suppose there is an HTML snippet that you want to include on your GitHub Pages web site, but Markdown doesn't offer a way to render it. What should you do?-Just add the HTML inline.
  • How do you enable GitHub Pages for your repository?-Select a Source from the GitHub Pages section of the Settings tab of your repository.
  • Which of the following cannot be hosted on GitHub Pages?-Dynamic server-side applications.
  • Which of the following would you most likely use to edit the body content of your GitHub Pages site?-Markdown
  • What is the primary function of a GitHub Action?-To automate software development tasks,To facilitate continuous integration and continuous delivery (CI/CD),Integrate infrastructure as code within your project's context
  • What are the two types of actions?-Container actions and JavaScript actions
  • Which of the following could not be used as an event trigger (runs_on)?-Opening a new tab in your browser
  • In which file do you define the steps to execute in your GitHub Action?-In a workflow .yml (YAML) file.
  • During the lab, which action did you use to publish container image to GitHub Package?-docker/build-push action step
  • When pulling the image to your local environment, which credentials are needed?-Your GitHub username and a Personal Access Token
  • In which scenarios should you NOT use GitHub Packages?-When I want to share code between methods of my application.
  • Which tool do you need to use a package hosted in GitHub Packages in your project?-The package manager tooling (npm, nuget.exe, ...).
  • How can you authenticate to GitHub Packages from your local development environment-With a Personal Access Token
  • In basketball stats, what does PER stand for?-Player efficiency rating
  • In this module, how did you impute data that's normally distributed?-

    Mean imputation
  • What is cross-validation?-A programmatic way to split data into n training and testing subsets to test the accuracy of a model.
  • What type of machine learning model is effective for predicting one value based on many other values?-Linear regression
  • What is one way to create randomized sample data that is close to accurate?-Use a random number within the standard deviation of input values for a machine learning algorithm.
  • Static web apps in Azure take significant expertise to develop and deploy.-False - Static web apps in Azure have many entry points and can be novice-friendly.
  • Flask is a framework for building web apps in which of the following languages?-Python only
  • What is the default port number that Flask uses to service HTTP requests?-5000
  • In what subdirectory should Jinja template files be stored by default?-templates
  • What is the name of the HTTP header that carries API keys in calls to Azure Cognitive Services?-Ocp-Apim-Subscription-Key
Azure Developer League: DevOps & GitHub Challenge


Share:

2 Comments:

  1. Hello team, the entire progress of Git and Git Hub, as a fresher I can understand easily the concepts, and if any one ask for Git Hub learning I will prefer this blog... Keep sharing!!! For getting DevOps Training in Chennai contact us...

    ReplyDelete

Please don't enter any spam link in the comment box

subscribe

IOE ALL SUB NOTES

Delivered by FeedBurner

Wikipedia

Search results

The quality of being the only one of its kind.

If you are fresher or preparing to attempt the Back Exam then you are going to be happy to know that here you will find all the shortlisted targeted question for your subject. Here you will find perfect answers to your questions