From the course: Certified Entry-Level Python Programmer (PCEP-30-02) Cert Prep
Unlock the full course today
Join today to access over 24,800 courses taught by industry experts.
Using operators - Python Tutorial
From the course: Certified Entry-Level Python Programmer (PCEP-30-02) Cert Prep
Using operators
- [Instructor] Now it's time to talk about operators. There are different kind of operators in Python. We have the typically well known arithmetic operators, so the addition, subtraction, multiplication, division. But then we have also a couple that may be new to some of you. For example, the modulus or modular or also known as remainder, that will actually take the remainder of a division. We use double asterisk for exponentiation. Exponentiation is, for example, when you're raising two to the power of three. And we have floor division, and what is that? Floor division is double forward slash. It's going to be a division that will return always an integer. So if the division gives you a float number, so a decimal number, it's taking only the integer part of it. This is also known as integer division on other languages. When you're using these operators, if the two operands are integers, the operator returns an…
Practice while you learn with exercise files
Download the files the instructor uses to teach the course. Follow along and learn by watching, listening and practicing.
Contents
-
-
-
Fundamentals of Python12m 52s
-
(Locked)
Writing and executing Python code12m 46s
-
(Locked)
Python code structure10m 32s
-
(Locked)
PEP 8 style guidelines and indentation4m 30s
-
(Locked)
Variables and literals10m 55s
-
(Locked)
Output messages to the console4m 7s
-
(Locked)
Defining numerical representations9m 30s
-
(Locked)
Working with strings12m 14s
-
(Locked)
Using operators8m 57s
-
(Locked)
Receiving input data from the console5m 52s
-
-
-
-
-