CHAPTER 5
BUILT-IN FUNCTIONS
This chapter introduces you to Python built-in functions and how to define custom functions. If you have read the preceding chapters, you have already seen examples of defining custom functions. However, this chapter contains more extensive examples of functions.
The first part of this chapter discusses the differences among functions and methods and then introduces various built-in functions; it contains examples of the split(), join(), and range() functions. You will also learn about the built-in char class, and how to use this class to determine whether a character is a digit or an alphabetic character.
The second section shows you examples of user-defined functions, and the third section shows you how to handle ...
Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Read now
Unlock full access