Important
- Please use the Q&A section for asking your queries in the breakout section.
- All attendees will be muted by default. Please raise your hand ✋ if you would like to discuss any topic and organizer of your room will unmute you.
- Do not worry if you are not getting same response from GitHub Copilot as other members in the breakout room. We just have to reiterate the prompt based on the 4 pillars of the Prompt crafting, to get better results.
- For each section, complete the exercises in the sequential order.
This repo contains sample code exercises, which can be tested using GitHub Copilot.
- Generate documentation for the exercise1.cpp without using GitHub Copilot chat
Tip
For this exercise, try to use GitHub Copilot code completion option.
- Select exercise2.cpp and use GitHub Copilot Chat to understand the logic of the program. Generate the documentation and a README markdown file for the program.
- Add atleast 2 additional features to the existing C++ program of exercise2.cpp using GitHub Copilot
- Plan the unit testing of the additional features using GitHub Copilot
Tip
- Run the exercises on your IDE and if you encounter any compilation errors, ask GitHub Copilot to understand about the errors in terminal
- @terminal #terminalSelection fix or @terminal #terminalSelection explain
- You can also ask GitHub Copilot by expanding more on the prompt.
- Translate the codebase you have created to C# (or Java), generate unit test cases for the code and corresponding documentation
- Create a new C++ workspace, which will call an API from US National Weather Service to get the current temperature for a specific zipcode or city. The code should evaluate the temperature and identify the corresponding climate for that region.
Note
You are doing great! 🥳 Now lets try some more exercises, to revise the concepts you have learnt about GitHub Copilot 🙂
Note
- The goal is to make sure that you are familiar with concepts of GitHub Copilot
- Your focus is not to complete the whole list of exercises within the allocated time.
- Instead enjoy each of these exercises and explore how GitHub Copilot can help you to tackle even unknown codebase 🙂
- Understand the logic for the exercise3.cpp and add sufficient inline documentation using GitHub Copilot. Create a README markdown file for the program.
- Add an additional feature to the existing solution using GitHub Copilot prompt crafting techniques and create a unit test plan for the new features.
- Understand the COBOL file in exercise4.cbl and identify the underlying logic of the program. Translate the codebase in exercise2.cbl to C#, generate unit test cases for the code and corresponding documentation (including README markdown file).
- Understand the existing logic in exercise5.cs and verify whether there are any existing issues/vulnerabilities.
- Add an additional feature to the existing solution using GitHub Copilot prompt crafting techniques.
- Create unit test cases for the updated code and generate the documentation to the program in such a way that a person who is comparatively new to C# should be able to understand the logic.
- Verify the last_bonus_exercise.cpp program and verify how the smart pointer is implemented in the program.
- How can you modify the Animal class to add a new property to represent the age of the animal.
- How can you make the program thread safe?
- After making the above changes, create the unit test plan and add documentation.