Programming for Data Science, Lec 1: Python Basics (Arithmetic/Comparison/Logical Operators)

preview_player
Показать описание
#python #datascience #machinelearning

Arithmetic operations
+ for addition
- for subtraction
* for multiplication
/ for division
** for exponentiation

* Comparison operators in Python are used to compare values and return Boolean results (True or False).
* Equal to
* Not equal to
* Greater than
* Less than
* Greater than or equal to
* Less than or equal to
* Logical operators in Python are used to perform logical operations and manipulate Boolean values. The main logical operators are `and`, `or`, and `not`.
* The `and` operator returns True if both conditions on its left and right are True.
* The `or` operator returns True if at least one of the conditions on its left or right is True.
* The `not` operator returns the opposite Boolean value.
Рекомендации по теме