Functions in Python: Introduction


Overview/Description
Expected Duration
Lesson Objectives
Course Number
Expertise Level



Overview/Description

Explore how Python facilitates code reuse by using functions in this 17-video course, which shows learners how to define functions, learn passing arguments to functions, and returning values from functions. The functions you will examine change the state of the program, may have side effects, and have observable effects other than their return values. Since functions with side effects are hard to parallelize and use in a distributed environment, you will learn correct ways of returning values from functions. First, you will learn how to invoke functions by using both positional and keyword arguments. You will next work with positional input arguments in custom functions, and learn that these are required arguments, and how to order these arguments to invoke your function. You will next learn to use variable length arguments in defining custom functions. Finally, you will learn how keyword arguments or named arguments are a way to make the intent behind function invocation absolutely explicit, and help prevent bugs in programs that are especially hard to detect.



Expected Duration (hours)
2.1

Lesson Objectives

Functions in Python: Introduction

  • discover the key concepts covered in this course
  • recall and implement custom functions
  • define, invoke, and name functions
  • recall how functions work as objects
  • define and invoke functions with input arguments
  • reference global variables from within a function
  • recall the characteristics of working with positional arguments
  • return information from functions
  • write functions with multiple return statements
  • return complex data types from functions
  • specify keyword arguments while invoking functions
  • recall nuances in invoking functions using keyword arguments
  • specify default values for function arguments
  • implement functions with *args variable length positional arguments
  • combine positional and variable length arguments
  • implement functions with **kwargs variable length keyword arguments
  • recall characteristics of functions, input arguments, and return values
  • Course Number:
    it_pyfcaldj_01_enus

    Expertise Level
    Beginner