Python Decorators: Mastering Functions that Return Functions — LearnFlat
⏱ 3 ساعة 📚 30 دورة 🎧 النسخة الصوتية

Python Decorators: Mastering Functions that Return Functions

Learn how to write and apply custom Python decorators to modify function behavior, write cleaner code, and manage function metadata with modern type hints.

  • 💬 مدرب ذكاء اصطناعي
    اسأل عن أي درس واحصل على إجابة واضحة فورًا، في أي وقت.
  • 🕐 ابدأ في أي وقت
    بلا جداول أو مواعيد نهائية — تعلّم بوتيرتك، وقتما يناسبك.
  • 🌐 بالعربية
    الدروس والمهام والشهادة — كل ذلك بلغتك بالكامل.

حول هذه الدورة

Have you ever wanted to modify the behavior of a Python function without changing its actual source code? Python decorators offer an elegant, powerful way to wrap functions and extend their capabilities, but understanding how they take and return function objects can be a hurdle for many programmers. This text-based course guides you step-by-step through the core concepts of first-class functions, closures, and decorator syntax. You will transition from writing basic wrapper functions to designing robust, reusable decorators that streamline your development workflow. In this course, you will: - Understand the foundational mechanics of first-class functions and how Python treats functions as objects. - Create custom decorator functions that take other functions as arguments and return modified versions. - Apply functools.wraps to preserve vital function metadata like docstrings and names. - Implement modern Python type hints for decorators to ensure code clarity and robust type checking. - Practice building real-world decorators for logging, timing execution, and access control through written exercises. The course starts with essential terminology and the fundamental mechanics of closures before moving on to practical decorator patterns and modern best practices. You will read clear explanations, analyze structured code examples, and reinforce your learning with targeted written exercises. Designed for beginner to intermediate Python developers who want to deepen their understanding of functional programming concepts. No prior experience with decorators is required, though a basic familiarity with writing standard Python functions is helpful. Start reading today to unlock the full potential of Python's decorator syntax and write more maintainable code.

ما الذي ستحصل عليه

  • 📜 شهادة إتمام
    أضفها إلى ملفك على LinkedIn
  • 💬 مدرّس AI شخصي
    عالق في دورة؟ اسأل مدرّسك المدمج أي شيء، في أي وقت.
  • 🎧 النسخة الصوتية مضمَّنة
    تعلَّم أثناء تنقُّلك — دون شاشة
  • ♾️ وصول مدى الحياة
    عُد متى شئت، بلا انتهاء
  • 📱 الهاتف أو الكمبيوتر
    يعمل في أي مكان وعلى أي جهاز
  • 💸 استرداد خلال 14 يومًا
    دون أسئلة
  • ⚡ قصير ومركَّز
    3 ساعة من المحتوى التطبيقي

المراجعات

لا توجد مراجعات بعد — كن أول من يشارك تجربته.

اكتب مراجعة

☆☆☆☆☆
سنطلب منك تسجيل الدخول بعد الإرسال — تُحفظ مسودتك.

الأسئلة الشائعة

ما الذي أحتاجه لأخذ هذه الدورة؟ +

يكفي هاتف أو كمبيوتر متصل بالإنترنت. بدون تثبيتات أو أجهزة خاصة.

كيف يمكنني الدفع؟ +

بالبطاقة عبر Stripe. لا نخزن بيانات البطاقة — يتولى Stripe ذلك بأمان.

هل يمكنني استرداد المال؟ +

نعم — استرداد كامل خلال 14 يومًا، دون أسئلة.

إلى متى يستمر وصولي؟ +

إلى الأبد. بمجرد الشراء، الدورة لك تعود إليها متى شئت.

هل سأحصل على شهادة؟ +

نعم. عند الإتمام ستحصل على شهادة يمكنك إضافتها إلى ملفك في LinkedIn.

مصمَّم للعاملين في
التقنية التصميم المالية التسويق الرعاية الصحية التعليم الضيافة التصنيع