0% found this document useful (0 votes)
34 views10 pages

Lecture 2 - Introduction To Python

Uploaded by

k61.2215115255
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
34 views10 pages

Lecture 2 - Introduction To Python

Uploaded by

k61.2215115255
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 10

INTRODUCTION TO

PYTHON

AID300: AI in the era of digital transformation

Python
The Jupiter Notebooks

https://www.anaconda.com/download

Machine Learning
Python

 Python is a high-level, interpreted programming language


that is known for its clear syntax and readability. It supports
multiple programming paradigms, including procedural,
object-oriented, and functional programming.
 Python is widely used in many areas such as web
development, data analysis, artificial intelligence, machine
learning, automation, and more.
Machine Learning

Python

Machine Learning
Python

• Variables in Python
• Data Types in Python
Integer (int): 1, 2, 5,… List (list): [1, 2, ‘abc’]
Float (float): 1.2. 3.41… Tuple (tuple): (5, 6, 7)
Boolean (bool): true, false Sets (set): {‘cookies, ‘chocolate’}
String (str): ‘a’, “cat”… Dictionaries (dict):
“dog”:1, “cat”:2)
Machine Learning

Operators

• Comparison, Logical, and Membership Operators in Python

Machine Learning
Operators

• Comparison, Logical, and Membership Operators in Python

Machine Learning

Operators

• Comparison, Logical, and Membership Operators in Python

Machine Learning
If Else Statements

Machine Learning

Loops

Machine Learning
Loops

Machine Learning

Functions

Machine Learning
Objects and Class

• Python has many different kinds of data types


• In Python, each is an object

Machine Learning

Objects and Class

• A class or type's methods are functions that every instance of


that class or type provides.
• It's how you interact with the object.
• We have been using methods all this time, for example, on lists.
• Sorting is an example of a method that interacts with the data in
the object.

Machine Learning
Objects and Class

Machine Learning

Objects and Class

Machine Learning
Objects and Class

Machine Learning

Objects and Class

Machine Learning
Objects and Class

Machine Learning

You might also like