Home of real teaching & learning
  • Full support for teachers
  • Focus on critical thinking
  • Engaging classroom activities
  • Integrated student eBook
  • Assessed tasks / qBank
  • Practice exam questions

The InThinking Guarantee: Our sites are written by expert practitioners and not by AI

See our AI policy

Disclaimer: InThinking subject sites are neither endorsed by nor connected with the International Baccalaureate Organisation.

Don't miss out, find out!

B 3.1.4 Worksheet Python

Example 1: Consider a class named Dog. A dog has attributes like name (str), breed (str), and age (int). Task 1: Define the Dog class in Python with an __init__ method. Task 2: Instantiate two Dog objects. Give them different names, breeds, and ages. Activity 1: Consider a class named Book. A book has attributes like title (str), author (str), and pages (int). Activity 2: Think of a real-world object (e.g., a...

Help