البرمجة الكائنية في بايثون
انتقل من الدوال المستقلة إلى تنظيم الكود في أصناف وكائنات قابلة لإعادة الاستخدام.
🐍 Try Python right here
Write code below and click Run — it executes right in your browser, nothing is sent to any server.
Output will appear here.
الدروس
1
الخصائص والدوال داخل الصنف
كل كائن يحمل خصائصه الخاصة (attributes) ويمكنه تنفيذ سلوكيات (methods) معرّفة داخل الصنف.
✏️ Practice this lesson:
Output will appear here.