Lesson 3.3 Learning Algorithms in Coding with AI Tools like ChatGPT

Lesson 3.3 Learning Algorithms in Coding with AI Tools like ChatGPT

Activity 3.3.2: Calculating the GCD

Activity 3.3.2: Calculating the GCD

Learning Objective:
By completing this activity, students will develop programming skills and enhance their problem-solving abilities by writing and testing a Python program to calculate the greatest common divisor (GCD) of two numbers, with support from ChatGPT for guidance and explanations.

Instructions:

  1. Write a Python program to calculate the GCD of two numbers with the assistance of ChatGPT.
  2. Test your program to ensure it works correctly.
  3. Use ChatGPT for explanations if you encounter any challenges in understanding the code or other related concepts during the process.
  4. Once your program is complete, assist your peers if they need help.
  5. Review one of your peer's codes:
    • Pick one line of their code and ask them to explain it to you.
    • Provide constructive feedback based on their explanation.
  6. Post a screenshot of your code and results in the discussion forum.
⏩ Go to CollaborationBook to complete this activity

您已完成此程序教学的0%
0%