Python 3 (Part 4 of 6): Functions and Classes
Interactive

Python 3 (Part 4 of 6): Functions and Classes

Biz Library
Updated Feb 04, 2020

In this course we’re going to start with a look at Functions and Functions are particularly important in Python, because one of the strengths of Python is the fact that it is a functional language. We'll start off by taking a look at the Def key word. That's how you define a Function. Next we’ll look at Default Arguments, Doc Strings, Variadic Functions, and Factorial. Then we will move onto some of the more advanced topics. We will talk about Function Objects. Then we will talk about Lambda expressions, which are a particularly compact representation for a function. Then we will go onto Generators, which are a more sophisticated example of the kinds of things you can do with Functions and then we’ll move onto Closures. Next we are going to talk about Classes, and the concept of a class is basically the idea of a programmer defined data type that you can define within your application. So after we are finished talking about how to define a class, we are going to talk about how to implement the code that is responsible for initializing a new instance of that class, which is Object Initialization. Then we will work on Classic Static Members that we can define that are associated with the class as a whole, rather than a particular instance of that class. And then we'll talk about Class Inheritance and then the final important aspect of object oriented programming that we will take a look at is something known as Data Hiding.


Lesson 1:

  • The def Keyword
  • Demo: The def Keyword.

Lesson 2:

  • Simple Functions
  • Demo: Functions.

Lesson 3:

  • Default Arguments
  • Demo: Default Arguments.

Lesson 4:

  • Doc Strings
  • Demo: Doc Strings.

Lesson 5:

  • Variadic Functions
  • Demo: Variadic Functions.

Lesson 6:

  • Factorial Function
  • Demo: Factorial Function.

Lesson 7:

  • Function Objects
  • Demo: Function Objects.

Lesson 8:

  • Lambda Expressions
  • Demo: Lambda Expressions.

Lesson 9:

  • Generators
  • Demo: Generators.

Lesson 10:

  • Closures
  • Demo: Closures.

Lesson 11:

  • Defining Classes
  • Demo: Classes.

Lesson 12:

  • Object Initialization
  • Demo: Object Initialization.

Lesson 13:

  • Class Static Members
  • Demo: Class Static Members.

Lesson 14:

  • Class Inheritance
  • Demo: Class Inheritance.

Lesson 15:

  • Data Hiding
  • Demo: Data Hiding.