SlideShare una empresa de Scribd logo
1 de 45
Descargar para leer sin conexión
1 of 45Module 5 : Numbers and Built‐in Functions
Introduction to       
Computational Thinking
Module 5 :
Numbers and Built‐in Functions
Asst Prof Chi‐Wing FU, Philip
Office: N4‐02c‐104
email: cwfu[at]ntu.edu.sg
2 of 45Module 5 : Numbers and Built‐in Functions
Topics
• More on Numbers
• Built-in functions
• Comparing floating point numbers
• Case Study: Finding Square Root
• Self Study: Bitwise operators (optional)
3 of 45Module 5 : Numbers and Built‐in Functions
More on Numbers
• Integers and Floating point numbers
• Their representations in computers
• Data range
• Optional: Bitwise operators on integers
4 of 45Module 5 : Numbers and Built‐in Functions
Memory: Bits and Bytes
• 1 Byte = 8 bits (each bit either 0 or 1)
• 1 Byte has 28 different variations, i.e., 256
• How about 4 bytes?
0
0
0
0
0
0
0
0 0
0
00
1
11
1
1
1
1
1
1
1111000
1001
1002
Contents of
memory
Memory
This is also covered in
Introduction to Computing Systems
5 of 45Module 5 : Numbers and Built‐in Functions
Integers (others)
• In most programming languages, an
integer takes up 4 bytes. The first bit for
sign: +ve or -ve, i.e., 31 bits left
• Since there is a zero needed to be
represented (as all zeros in the 32 bits),
the available data range is [-231, +231 – 1 ]
6 of 45Module 5 : Numbers and Built‐in Functions
Integers (Python)
• Integers in Python has unlimited precision
• This is a useful feature in Python; otherwise,
we (programmers) have to handle them
ourselves through programming effort
7 of 45Module 5 : Numbers and Built‐in Functions
Float
• For real numbers with decimals
• Limited precision because we use limited
number of bits to store the data in a special
format (you will learn later in other course):
• Max. representable finite float
• Min. positive normalized float
Want to know more? http://docs.python.org/tutorial/floatingpoint.html
http://en.wikipedia.org/wiki/Double_precision_floating-point_format
8 of 45Module 5 : Numbers and Built‐in Functions
Float
• and it has limited precision…
• Hence, computation results with floats
may not be exact
9 of 45Module 5 : Numbers and Built‐in Functions
Integer VS Float
• When writing programs, variables that are
numeric can be integers or floats
• So… how to choose?
Think about the context!!!
Need decimal values? Want precision?
10 of 45Module 5 : Numbers and Built‐in Functions
Integer VS Float
• For the followings, which type is
more appropriate?
• Age
• Height
• Volume of a container
• Exchange rate
• Voltage and current
• Number of students in a class
• Bank account balance
11 of 45Module 5 : Numbers and Built‐in Functions
Topics
• More on Numbers
• Built-in functions
• Comparing floating point numbers
• Case Study: Finding Square Root
• Self Study: Bitwise operators (optional)
12 of 45Module 5 : Numbers and Built‐in Functions
What are Built-in functions
• Built-in functions are subroutines, procedures,
or methods that are built into Python itself; each
provides a specific functionality
• See the Python standard library:
http://docs.python.org/library/functions.html
• In fact, you knew some of them already:
• print (for displaying data)
• input (for reading user input)
• float, int, str (for converting data)
• type (for checking data type)
• exec (for executing a string in Python), …, etc.
13 of 45Module 5 : Numbers and Built‐in Functions
• abs(x) – Return absolute value of x
• min(x,y) and max(x,y) – Return minimum
and maximum of x and y, respectively
They allow two or
more arguments
Let’s learn more: calling & arg(s)
Takes one argument
14 of 45Module 5 : Numbers and Built‐in Functions
More Built-in Functions
• math.ceil(x) and math.floor(x) –
Return the ceiling and floor of x as “int”
Remember to
import math
15 of 45Module 5 : Numbers and Built‐in Functions
More Built-in Functions
• math.pow(x,y) – Return x raised to the power y
• math.sqrt(x) – Return the square root of x
• math.log(x) – Return natural logarithm of x
• math.log10(x) – Return base-10 logarithm of x
Math functions
usually return
“float”
16 of 45Module 5 : Numbers and Built‐in Functions
More Built-in Functions
• math.sin(x), math.cos(x), math.tan(x)
– Return the sine, cosine, and tangent of x (radian)
• math.asin(x),math.acos(x),math.atan(x)
– Return arc sin, cos, and tan of x in radian
(Note: they all use radian!)
• math.degrees(x) and math.radians(x)
– Return x in degrees and radians, respectively
17 of 45Module 5 : Numbers and Built‐in Functions
Help Function
• help(“...”) – display help information on a
Python function or module
18 of 45Module 5 : Numbers and Built‐in Functions
Topics
• More on Numbers
• Built-in functions
• Comparing floating point numbers
• Case Study: Finding Square Root
• Self Study: Bitwise operators (optional)
19 of 45Module 5 : Numbers and Built‐in Functions
No Equality!
• If we want to know if two floating point numbers
are equal or not, can we use "==" ??
• It is tricky!!!
They are not equal! Why?
So… how to fix it?
20 of 45Module 5 : Numbers and Built‐in Functions
So… how to check?
• First, we can define a relatively small floating
point value, usually called epsilon or tolerance
• IDEA: if the absolute difference between the
two floating point numbers is smaller than
epsilon, we say that their values are the same
Key idea!!!!
(computationally but not mathematically)
21 of 45Module 5 : Numbers and Built‐in Functions
Topics
• More on Numbers
• Built-in functions
• Comparing floating point numbers
• Case Study: Finding Square Root
• Self Study: Bitwise operators (optional)
22 of 45Module 5 : Numbers and Built‐in Functions
Case Study
• Here we want to implement an algorithm to
compute the square root of a value without
using math.sqrt
You should implement, run, and try the case
study yourself in the course
23 of 45Module 5 : Numbers and Built‐in Functions
Algorithm: compute square root
• We can compute the square root of a value,
say x, iteratively using the following idea:
Given x,
first compute an initial guess: guess = x/2
then diff = guess* guess - x
if abs(diff) < epsilon, we are done
if diff > 0, guess is too large
if diff < 0, guess is too small
update guess so that it gets closer, then
Repeat
24 of 45Module 5 : Numbers and Built‐in Functions
Algorithm: compute square root
• But… how to update guess so that it gets
closer in every iteration…
• Let’s check x/guess…
In case x=100 and guess=50,
x/guess = 2
the targeting square root value should always
lie between guess and x/guess!
• So… we may update guess as mean value of
guess and x/guess and make it closer!
25 of 45Module 5 : Numbers and Built‐in Functions
Algorithm: compute square root
Let’s do this test…
• Iteration #1
x=100 and guess=50
x/guess=2 -> new guess = mean = 26
• Iteration #2
x=100 and guess=26
x/guess=3.846 -> new guess = mean = 14.923
• Iteration #3
x=100 and guess=14.923
x/guess=6.701 -> new guess = mean = 10.812
…………
Really getting closer and closer!!!
26 of 45Module 5 : Numbers and Built‐in Functions
Implementation
• Here is the Python implementation
We will learn “while” in module 6.2
27 of 45Module 5 : Numbers and Built‐in Functions
Implementation
• Add variable "iter" to count number of iterations
Add iteration counter
28 of 45Module 5 : Numbers and Built‐in Functions
Verification… by math.sqrt
• Lastly… we must verify our program!!!
Report the difference
This is a verification
29 of 45Module 5 : Numbers and Built‐in Functions
Testing #1
• We try with x = 100
Our result
Difference is very small
30 of 45Module 5 : Numbers and Built‐in Functions
Testing #2
• We try with x = 100000
Our result
But…
need more
iterations for
larger num.
Difference
still small
31 of 45Module 5 : Numbers and Built‐in Functions
Testing #3
• Lastly… try with x = 2
Difference is still very small
Fewer
iterations
this time
Our result
32 of 45Module 5 : Numbers and Built‐in Functions
Topics
• More on Numbers
• Built-in functions
• Comparing floating point numbers
• Case Study: Finding Square Root
• Self Study: Bitwise operators (optional)
33 of 45Module 5 : Numbers and Built‐in Functions
What are Bitwise operators
• Recall that integers are stored in binary, e.g.,
34 of 45Module 5 : Numbers and Built‐in Functions
NOT~
SHIFT (right)>>
SHIFT (left)<<
Bitwise XOR^
Bitwise OR|
Bitwise AND&
meaningoperator
What are Bitwise operators
• Python provides bitwise operators that process
input integers bit by bit correspondingly
• Treat 1 as true and 0 as false
Input:
15 -> 0000 1111
17 -> 0001 0001
What is 15 | 17 ?
All are binary
operations except ~,
which is unary
35 of 45Module 5 : Numbers and Built‐in Functions
00 & 0
00 & 1
01 & 0
11 & 1
ResultAND
Truth tables of &, |, ^, ~
00 | 0
10 | 1
11 | 0
11 | 1
ResultOR
00 ^ 0
10 ^ 1
11 ^ 0
01 ^ 1
ResultXOR
• XOR is called exclusive or; it is true ONLY if one
of the two bits is true (but not both)
• ~x is a special operation called 2’s complement,
which is just -x-1, i.e., ~2 gives -3
36 of 45Module 5 : Numbers and Built‐in Functions
Examples: &, |, ^
&
|
^
37 of 45Module 5 : Numbers and Built‐in Functions
Examples: shift <<, >>
<<
>>
38 of 45Module 5 : Numbers and Built‐in Functions
3 << 1 gives 6SHIFT (left)<<
~3 gives -4NOT~
3 >> 1 gives 1SHIFT (right)>>
3 ^ 2 gives 1Bitwise XOR^
3 | 2 gives 3Bitwise OR|
3 & 2 gives 2Bitwise AND&
examplesmeaningoperator
More examples
Try to work them out yourself
39 of 45Module 5 : Numbers and Built‐in Functions
Any Application?
1. Simple Data Encryption and Decryption
using the xor operator
2. Pseudo Random Number Generator
(PRNG)
40 of 45Module 5 : Numbers and Built‐in Functions
Application #1
• xor can be used for doing simple encryption
and decryption
• Given
D – our data (any integer, i.e., 32 bits)
K – our key in encryption (which is an integer)
• We can perform encryption by:
E = D xor K where E is the encrypted integer
• and decryption by
E xor K gives D
We can recover D from E using K
XOR has this interesting property
Why? Study the truth table…
41 of 45Module 5 : Numbers and Built‐in Functions
Application #2
• Pseudo Random Number Generator (PRNG):
• Seed – A number to initialize the generator
• Random number sequence – Use seed as
input, we apply the generator to obtain the first
random number; then use it as input to
generate the next random number, and so on…
See http://docs.python.org/library/random.html
• In designing a PRNG, bitwise operations are
often used, see next slide for a simple example
Interesting article:
http://spectrum.ieee.org/semiconductors/processors/behind-intels-new-randomnumber-generator
42 of 45Module 5 : Numbers and Built‐in Functions
Application #2 (cont.)
• Example: Define a function “parityOf” to
compute the parity of an integer:
A bit to add to an integer to make the
number of 1s in its binary form to be even
Define a simple 12-bit PRNG
A sequence of random number
(binary numbers) can be
generated starting from the seed
note: 0x indicates
hexidecimal format
43 of 45Module 5 : Numbers and Built‐in Functions
Application #2 (cont.)
• Note:
• You will learn how to use Python keyword “def” to
define functions later in this course
• Using bitwise operators, we can efficiently compute the
parity and develop pseudorandom number generators.
There are many PRNGs in the world; some are more
complicated, and they could have different quality…
• Since the numbers generated in the example code
form a binary number sequence, we also call it a
Pseudo Random Binary Sequence Generator (PRBSG)
• Related courses in the future:
“Computer Organization and Architecture” and
“Microprocessor-based System Design”
44 of 45Module 5 : Numbers and Built‐in Functions
Take Home Messages
• Integers, Long, and Floating point numbers
– Representation and property: data range, minimum and
maximum values, and precision
• Built-in functions are useful resources built into
Python itself
• Comparing floating point numbers can be tricky
(and error-prone)
– Use absolute difference against a small epsilon to test
equality for floating point numbers
45 of 45Module 5 : Numbers and Built‐in Functions
Reading Assignment
• Textbook
Chapter 1: Beginnings
1.8 to 1.10
Note: Though some material (1.10) in textbook is
not directly related to the lecture material, you can
learn more from them.

Más contenido relacionado

La actualidad más candente

Algorithm chapter 2
Algorithm chapter 2Algorithm chapter 2
Algorithm chapter 2chidabdu
 
Matlab solved problems
Matlab solved problemsMatlab solved problems
Matlab solved problemsMake Mannan
 
01 intro to algorithm--updated 2015
01 intro to algorithm--updated 201501 intro to algorithm--updated 2015
01 intro to algorithm--updated 2015Hira Gul
 
Design and analysis of Algorithm By Dr. B. J. Mohite
Design and analysis of Algorithm By Dr. B. J. MohiteDesign and analysis of Algorithm By Dr. B. J. Mohite
Design and analysis of Algorithm By Dr. B. J. MohiteZeal Education Society, Pune
 
Algorithm analysis (All in one)
Algorithm analysis (All in one)Algorithm analysis (All in one)
Algorithm analysis (All in one)jehan1987
 
Data Structures and Algorithm Analysis
Data Structures  and  Algorithm AnalysisData Structures  and  Algorithm Analysis
Data Structures and Algorithm AnalysisMary Margarat
 
(2) cpp imperative programming
(2) cpp imperative programming(2) cpp imperative programming
(2) cpp imperative programmingNico Ludwig
 
Searching techniques with progrms
Searching techniques with progrmsSearching techniques with progrms
Searching techniques with progrmsMisssaxena
 
Programming Logic and Design: Working with Data
Programming Logic and Design: Working with DataProgramming Logic and Design: Working with Data
Programming Logic and Design: Working with DataNicole Ryan
 
Recursion | C++ | DSA
Recursion | C++ | DSARecursion | C++ | DSA
Recursion | C++ | DSASumit Pandey
 
MATLAB - The Need to Know Basics
MATLAB - The Need to Know BasicsMATLAB - The Need to Know Basics
MATLAB - The Need to Know BasicsSTEM Course Prep
 
Recurrence Relation
Recurrence RelationRecurrence Relation
Recurrence RelationNilaNila16
 

La actualidad más candente (20)

Algorithm chapter 2
Algorithm chapter 2Algorithm chapter 2
Algorithm chapter 2
 
chapter 1
chapter 1chapter 1
chapter 1
 
Matlab solved problems
Matlab solved problemsMatlab solved problems
Matlab solved problems
 
Analysis of algorithm
Analysis of algorithmAnalysis of algorithm
Analysis of algorithm
 
Matlab tutorial 4
Matlab tutorial 4Matlab tutorial 4
Matlab tutorial 4
 
Lecture5 syntax analysis_1
Lecture5 syntax analysis_1Lecture5 syntax analysis_1
Lecture5 syntax analysis_1
 
01 intro to algorithm--updated 2015
01 intro to algorithm--updated 201501 intro to algorithm--updated 2015
01 intro to algorithm--updated 2015
 
Design & Analysis Of Algorithm
Design & Analysis Of AlgorithmDesign & Analysis Of Algorithm
Design & Analysis Of Algorithm
 
Design and analysis of Algorithm By Dr. B. J. Mohite
Design and analysis of Algorithm By Dr. B. J. MohiteDesign and analysis of Algorithm By Dr. B. J. Mohite
Design and analysis of Algorithm By Dr. B. J. Mohite
 
Chap 5 c++
Chap 5 c++Chap 5 c++
Chap 5 c++
 
Algorithm analysis (All in one)
Algorithm analysis (All in one)Algorithm analysis (All in one)
Algorithm analysis (All in one)
 
Data Structures and Algorithm Analysis
Data Structures  and  Algorithm AnalysisData Structures  and  Algorithm Analysis
Data Structures and Algorithm Analysis
 
(2) cpp imperative programming
(2) cpp imperative programming(2) cpp imperative programming
(2) cpp imperative programming
 
Searching techniques with progrms
Searching techniques with progrmsSearching techniques with progrms
Searching techniques with progrms
 
Programming Logic and Design: Working with Data
Programming Logic and Design: Working with DataProgramming Logic and Design: Working with Data
Programming Logic and Design: Working with Data
 
Daa notes 1
Daa notes 1Daa notes 1
Daa notes 1
 
Lecture6 syntax analysis_2
Lecture6 syntax analysis_2Lecture6 syntax analysis_2
Lecture6 syntax analysis_2
 
Recursion | C++ | DSA
Recursion | C++ | DSARecursion | C++ | DSA
Recursion | C++ | DSA
 
MATLAB - The Need to Know Basics
MATLAB - The Need to Know BasicsMATLAB - The Need to Know Basics
MATLAB - The Need to Know Basics
 
Recurrence Relation
Recurrence RelationRecurrence Relation
Recurrence Relation
 

Destacado

Lecture 2 introduction to python
Lecture 2  introduction to pythonLecture 2  introduction to python
Lecture 2 introduction to pythonalvin567
 
Lecture 0 beginning
Lecture 0  beginningLecture 0  beginning
Lecture 0 beginningalvin567
 
Lecture 4 variables data types and operators
Lecture 4  variables data types and operatorsLecture 4  variables data types and operators
Lecture 4 variables data types and operatorsalvin567
 
Lecture 6.1 flow control selection
Lecture 6.1  flow control selectionLecture 6.1  flow control selection
Lecture 6.1 flow control selectionalvin567
 
Lecture 6.2 flow control repetition
Lecture 6.2  flow control repetitionLecture 6.2  flow control repetition
Lecture 6.2 flow control repetitionalvin567
 
Lecture 7 program development issues (supplementary)
Lecture 7  program development issues (supplementary)Lecture 7  program development issues (supplementary)
Lecture 7 program development issues (supplementary)alvin567
 
Lecture 8 strings and characters
Lecture 8  strings and charactersLecture 8  strings and characters
Lecture 8 strings and charactersalvin567
 
Lecture 11 file management
Lecture 11  file managementLecture 11  file management
Lecture 11 file managementalvin567
 
Play with python lecture 2
Play with python lecture 2Play with python lecture 2
Play with python lecture 2iloveallahsomuch
 
Lecture 10 user defined functions and modules
Lecture 10  user defined functions and modulesLecture 10  user defined functions and modules
Lecture 10 user defined functions and modulesalvin567
 
Programming for Everybody in Python
Programming for Everybody in PythonProgramming for Everybody in Python
Programming for Everybody in PythonCharles Severance
 
Lecture 1 computing and algorithms
Lecture 1  computing and algorithmsLecture 1  computing and algorithms
Lecture 1 computing and algorithmsalvin567
 
Lecture 12 exceptions
Lecture 12  exceptionsLecture 12  exceptions
Lecture 12 exceptionsalvin567
 

Destacado (20)

Lecture 2 introduction to python
Lecture 2  introduction to pythonLecture 2  introduction to python
Lecture 2 introduction to python
 
Python 3 Days
Python  3 DaysPython  3 Days
Python 3 Days
 
Lecture 0 beginning
Lecture 0  beginningLecture 0  beginning
Lecture 0 beginning
 
Lecture 4 variables data types and operators
Lecture 4  variables data types and operatorsLecture 4  variables data types and operators
Lecture 4 variables data types and operators
 
Lecture 6.1 flow control selection
Lecture 6.1  flow control selectionLecture 6.1  flow control selection
Lecture 6.1 flow control selection
 
Lecture 6.2 flow control repetition
Lecture 6.2  flow control repetitionLecture 6.2  flow control repetition
Lecture 6.2 flow control repetition
 
Lecture 7 program development issues (supplementary)
Lecture 7  program development issues (supplementary)Lecture 7  program development issues (supplementary)
Lecture 7 program development issues (supplementary)
 
Lecture 8 strings and characters
Lecture 8  strings and charactersLecture 8  strings and characters
Lecture 8 strings and characters
 
Python Tutorial
Python TutorialPython Tutorial
Python Tutorial
 
Lecture 11 file management
Lecture 11  file managementLecture 11  file management
Lecture 11 file management
 
Play with python lecture 2
Play with python lecture 2Play with python lecture 2
Play with python lecture 2
 
Mba
MbaMba
Mba
 
Lecture 10 user defined functions and modules
Lecture 10  user defined functions and modulesLecture 10  user defined functions and modules
Lecture 10 user defined functions and modules
 
Introduction to WEB HTML, CSS
Introduction to WEB HTML, CSSIntroduction to WEB HTML, CSS
Introduction to WEB HTML, CSS
 
Python GUI Course Summary - 7 Modules
Python GUI Course Summary - 7 ModulesPython GUI Course Summary - 7 Modules
Python GUI Course Summary - 7 Modules
 
Programming for Everybody in Python
Programming for Everybody in PythonProgramming for Everybody in Python
Programming for Everybody in Python
 
Lecture 1 computing and algorithms
Lecture 1  computing and algorithmsLecture 1  computing and algorithms
Lecture 1 computing and algorithms
 
Training Google Drive and Hangouts.pptx
Training Google Drive and Hangouts.pptxTraining Google Drive and Hangouts.pptx
Training Google Drive and Hangouts.pptx
 
Python - Lecture 1
Python - Lecture 1Python - Lecture 1
Python - Lecture 1
 
Lecture 12 exceptions
Lecture 12  exceptionsLecture 12  exceptions
Lecture 12 exceptions
 

Similar a Lecture 5 numbers and built in functions

Functional Python Webinar from October 22nd, 2014
Functional Python Webinar from October 22nd, 2014Functional Python Webinar from October 22nd, 2014
Functional Python Webinar from October 22nd, 2014Reuven Lerner
 
Updatedpython.pptxUpdatedpython.pptxUpdatedpython.pptx
Updatedpython.pptxUpdatedpython.pptxUpdatedpython.pptxUpdatedpython.pptxUpdatedpython.pptxUpdatedpython.pptx
Updatedpython.pptxUpdatedpython.pptxUpdatedpython.pptxZahouAmel1
 
Introduction to Python for Plone developers
Introduction to Python for Plone developersIntroduction to Python for Plone developers
Introduction to Python for Plone developersJim Roepcke
 
Basic elements of java
Basic elements of java Basic elements of java
Basic elements of java Ahmad Idrees
 
04 Functional Programming in Python
04 Functional Programming in Python04 Functional Programming in Python
04 Functional Programming in PythonEbad ullah Qureshi
 
Functions, List and String methods
Functions, List and String methodsFunctions, List and String methods
Functions, List and String methodsPranavSB
 
Basic concept of Python.pptx includes design tool, identifier, variables.
Basic concept of Python.pptx includes design tool, identifier, variables.Basic concept of Python.pptx includes design tool, identifier, variables.
Basic concept of Python.pptx includes design tool, identifier, variables.supriyasarkar38
 
if, while and for in Python
if, while and for in Pythonif, while and for in Python
if, while and for in PythonPranavSB
 
Basic Python Programming: Part 01 and Part 02
Basic Python Programming: Part 01 and Part 02Basic Python Programming: Part 01 and Part 02
Basic Python Programming: Part 01 and Part 02Fariz Darari
 
Mathemetics module
Mathemetics moduleMathemetics module
Mathemetics modulemanikanta361
 
Python PCEP Comparison Operators And Conditional Execution
Python PCEP Comparison Operators And Conditional ExecutionPython PCEP Comparison Operators And Conditional Execution
Python PCEP Comparison Operators And Conditional ExecutionIHTMINSTITUTE
 

Similar a Lecture 5 numbers and built in functions (20)

Python4HPC.pptx
Python4HPC.pptxPython4HPC.pptx
Python4HPC.pptx
 
Python4HPC.pptx
Python4HPC.pptxPython4HPC.pptx
Python4HPC.pptx
 
Functional Python Webinar from October 22nd, 2014
Functional Python Webinar from October 22nd, 2014Functional Python Webinar from October 22nd, 2014
Functional Python Webinar from October 22nd, 2014
 
python ppt
python pptpython ppt
python ppt
 
Updatedpython.pptxUpdatedpython.pptxUpdatedpython.pptx
Updatedpython.pptxUpdatedpython.pptxUpdatedpython.pptxUpdatedpython.pptxUpdatedpython.pptxUpdatedpython.pptx
Updatedpython.pptxUpdatedpython.pptxUpdatedpython.pptx
 
Introduction to Python for Plone developers
Introduction to Python for Plone developersIntroduction to Python for Plone developers
Introduction to Python for Plone developers
 
Basic elements of java
Basic elements of java Basic elements of java
Basic elements of java
 
Lecture 1 (bce-7)
Lecture   1 (bce-7)Lecture   1 (bce-7)
Lecture 1 (bce-7)
 
04 Functional Programming in Python
04 Functional Programming in Python04 Functional Programming in Python
04 Functional Programming in Python
 
Functions, List and String methods
Functions, List and String methodsFunctions, List and String methods
Functions, List and String methods
 
Basic concept of Python.pptx includes design tool, identifier, variables.
Basic concept of Python.pptx includes design tool, identifier, variables.Basic concept of Python.pptx includes design tool, identifier, variables.
Basic concept of Python.pptx includes design tool, identifier, variables.
 
Unit 2 algorithm
Unit   2 algorithmUnit   2 algorithm
Unit 2 algorithm
 
if, while and for in Python
if, while and for in Pythonif, while and for in Python
if, while and for in Python
 
Basic Python Programming: Part 01 and Part 02
Basic Python Programming: Part 01 and Part 02Basic Python Programming: Part 01 and Part 02
Basic Python Programming: Part 01 and Part 02
 
PPS_Unit 1.pptx
PPS_Unit 1.pptxPPS_Unit 1.pptx
PPS_Unit 1.pptx
 
Python basics
Python basicsPython basics
Python basics
 
Unit - 2 CAP.pptx
Unit - 2 CAP.pptxUnit - 2 CAP.pptx
Unit - 2 CAP.pptx
 
Mathemetics module
Mathemetics moduleMathemetics module
Mathemetics module
 
Python PCEP Comparison Operators And Conditional Execution
Python PCEP Comparison Operators And Conditional ExecutionPython PCEP Comparison Operators And Conditional Execution
Python PCEP Comparison Operators And Conditional Execution
 
Programing techniques
Programing techniquesPrograming techniques
Programing techniques
 

Último

Apres-Cyber - The Data Dilemma: Bridging Offensive Operations and Machine Lea...
Apres-Cyber - The Data Dilemma: Bridging Offensive Operations and Machine Lea...Apres-Cyber - The Data Dilemma: Bridging Offensive Operations and Machine Lea...
Apres-Cyber - The Data Dilemma: Bridging Offensive Operations and Machine Lea...Will Schroeder
 
COMPUTER 10: Lesson 7 - File Storage and Online Collaboration
COMPUTER 10: Lesson 7 - File Storage and Online CollaborationCOMPUTER 10: Lesson 7 - File Storage and Online Collaboration
COMPUTER 10: Lesson 7 - File Storage and Online Collaborationbruanjhuli
 
Linked Data in Production: Moving Beyond Ontologies
Linked Data in Production: Moving Beyond OntologiesLinked Data in Production: Moving Beyond Ontologies
Linked Data in Production: Moving Beyond OntologiesDavid Newbury
 
UiPath Studio Web workshop series - Day 7
UiPath Studio Web workshop series - Day 7UiPath Studio Web workshop series - Day 7
UiPath Studio Web workshop series - Day 7DianaGray10
 
Secure your environment with UiPath and CyberArk technologies - Session 1
Secure your environment with UiPath and CyberArk technologies - Session 1Secure your environment with UiPath and CyberArk technologies - Session 1
Secure your environment with UiPath and CyberArk technologies - Session 1DianaGray10
 
OpenShift Commons Paris - Choose Your Own Observability Adventure
OpenShift Commons Paris - Choose Your Own Observability AdventureOpenShift Commons Paris - Choose Your Own Observability Adventure
OpenShift Commons Paris - Choose Your Own Observability AdventureEric D. Schabell
 
Crea il tuo assistente AI con lo Stregatto (open source python framework)
Crea il tuo assistente AI con lo Stregatto (open source python framework)Crea il tuo assistente AI con lo Stregatto (open source python framework)
Crea il tuo assistente AI con lo Stregatto (open source python framework)Commit University
 
UiPath Studio Web workshop series - Day 6
UiPath Studio Web workshop series - Day 6UiPath Studio Web workshop series - Day 6
UiPath Studio Web workshop series - Day 6DianaGray10
 
Spring24-Release Overview - Wellingtion User Group-1.pdf
Spring24-Release Overview - Wellingtion User Group-1.pdfSpring24-Release Overview - Wellingtion User Group-1.pdf
Spring24-Release Overview - Wellingtion User Group-1.pdfAnna Loughnan Colquhoun
 
Digital magic. A small project for controlling smart light bulbs.
Digital magic. A small project for controlling smart light bulbs.Digital magic. A small project for controlling smart light bulbs.
Digital magic. A small project for controlling smart light bulbs.francesco barbera
 
Nanopower In Semiconductor Industry.pdf
Nanopower  In Semiconductor Industry.pdfNanopower  In Semiconductor Industry.pdf
Nanopower In Semiconductor Industry.pdfPedro Manuel
 
Do we need a new standard for visualizing the invisible?
Do we need a new standard for visualizing the invisible?Do we need a new standard for visualizing the invisible?
Do we need a new standard for visualizing the invisible?SANGHEE SHIN
 
Designing A Time bound resource download URL
Designing A Time bound resource download URLDesigning A Time bound resource download URL
Designing A Time bound resource download URLRuncy Oommen
 
How to Effectively Monitor SD-WAN and SASE Environments with ThousandEyes
How to Effectively Monitor SD-WAN and SASE Environments with ThousandEyesHow to Effectively Monitor SD-WAN and SASE Environments with ThousandEyes
How to Effectively Monitor SD-WAN and SASE Environments with ThousandEyesThousandEyes
 
The Data Metaverse: Unpacking the Roles, Use Cases, and Tech Trends in Data a...
The Data Metaverse: Unpacking the Roles, Use Cases, and Tech Trends in Data a...The Data Metaverse: Unpacking the Roles, Use Cases, and Tech Trends in Data a...
The Data Metaverse: Unpacking the Roles, Use Cases, and Tech Trends in Data a...Aggregage
 
Introduction to Matsuo Laboratory (ENG).pptx
Introduction to Matsuo Laboratory (ENG).pptxIntroduction to Matsuo Laboratory (ENG).pptx
Introduction to Matsuo Laboratory (ENG).pptxMatsuo Lab
 
RAG Patterns and Vector Search in Generative AI
RAG Patterns and Vector Search in Generative AIRAG Patterns and Vector Search in Generative AI
RAG Patterns and Vector Search in Generative AIUdaiappa Ramachandran
 
Anypoint Code Builder , Google Pub sub connector and MuleSoft RPA
Anypoint Code Builder , Google Pub sub connector and MuleSoft RPAAnypoint Code Builder , Google Pub sub connector and MuleSoft RPA
Anypoint Code Builder , Google Pub sub connector and MuleSoft RPAshyamraj55
 
9 Steps For Building Winning Founding Team
9 Steps For Building Winning Founding Team9 Steps For Building Winning Founding Team
9 Steps For Building Winning Founding TeamAdam Moalla
 
NIST Cybersecurity Framework (CSF) 2.0 Workshop
NIST Cybersecurity Framework (CSF) 2.0 WorkshopNIST Cybersecurity Framework (CSF) 2.0 Workshop
NIST Cybersecurity Framework (CSF) 2.0 WorkshopBachir Benyammi
 

Último (20)

Apres-Cyber - The Data Dilemma: Bridging Offensive Operations and Machine Lea...
Apres-Cyber - The Data Dilemma: Bridging Offensive Operations and Machine Lea...Apres-Cyber - The Data Dilemma: Bridging Offensive Operations and Machine Lea...
Apres-Cyber - The Data Dilemma: Bridging Offensive Operations and Machine Lea...
 
COMPUTER 10: Lesson 7 - File Storage and Online Collaboration
COMPUTER 10: Lesson 7 - File Storage and Online CollaborationCOMPUTER 10: Lesson 7 - File Storage and Online Collaboration
COMPUTER 10: Lesson 7 - File Storage and Online Collaboration
 
Linked Data in Production: Moving Beyond Ontologies
Linked Data in Production: Moving Beyond OntologiesLinked Data in Production: Moving Beyond Ontologies
Linked Data in Production: Moving Beyond Ontologies
 
UiPath Studio Web workshop series - Day 7
UiPath Studio Web workshop series - Day 7UiPath Studio Web workshop series - Day 7
UiPath Studio Web workshop series - Day 7
 
Secure your environment with UiPath and CyberArk technologies - Session 1
Secure your environment with UiPath and CyberArk technologies - Session 1Secure your environment with UiPath and CyberArk technologies - Session 1
Secure your environment with UiPath and CyberArk technologies - Session 1
 
OpenShift Commons Paris - Choose Your Own Observability Adventure
OpenShift Commons Paris - Choose Your Own Observability AdventureOpenShift Commons Paris - Choose Your Own Observability Adventure
OpenShift Commons Paris - Choose Your Own Observability Adventure
 
Crea il tuo assistente AI con lo Stregatto (open source python framework)
Crea il tuo assistente AI con lo Stregatto (open source python framework)Crea il tuo assistente AI con lo Stregatto (open source python framework)
Crea il tuo assistente AI con lo Stregatto (open source python framework)
 
UiPath Studio Web workshop series - Day 6
UiPath Studio Web workshop series - Day 6UiPath Studio Web workshop series - Day 6
UiPath Studio Web workshop series - Day 6
 
Spring24-Release Overview - Wellingtion User Group-1.pdf
Spring24-Release Overview - Wellingtion User Group-1.pdfSpring24-Release Overview - Wellingtion User Group-1.pdf
Spring24-Release Overview - Wellingtion User Group-1.pdf
 
Digital magic. A small project for controlling smart light bulbs.
Digital magic. A small project for controlling smart light bulbs.Digital magic. A small project for controlling smart light bulbs.
Digital magic. A small project for controlling smart light bulbs.
 
Nanopower In Semiconductor Industry.pdf
Nanopower  In Semiconductor Industry.pdfNanopower  In Semiconductor Industry.pdf
Nanopower In Semiconductor Industry.pdf
 
Do we need a new standard for visualizing the invisible?
Do we need a new standard for visualizing the invisible?Do we need a new standard for visualizing the invisible?
Do we need a new standard for visualizing the invisible?
 
Designing A Time bound resource download URL
Designing A Time bound resource download URLDesigning A Time bound resource download URL
Designing A Time bound resource download URL
 
How to Effectively Monitor SD-WAN and SASE Environments with ThousandEyes
How to Effectively Monitor SD-WAN and SASE Environments with ThousandEyesHow to Effectively Monitor SD-WAN and SASE Environments with ThousandEyes
How to Effectively Monitor SD-WAN and SASE Environments with ThousandEyes
 
The Data Metaverse: Unpacking the Roles, Use Cases, and Tech Trends in Data a...
The Data Metaverse: Unpacking the Roles, Use Cases, and Tech Trends in Data a...The Data Metaverse: Unpacking the Roles, Use Cases, and Tech Trends in Data a...
The Data Metaverse: Unpacking the Roles, Use Cases, and Tech Trends in Data a...
 
Introduction to Matsuo Laboratory (ENG).pptx
Introduction to Matsuo Laboratory (ENG).pptxIntroduction to Matsuo Laboratory (ENG).pptx
Introduction to Matsuo Laboratory (ENG).pptx
 
RAG Patterns and Vector Search in Generative AI
RAG Patterns and Vector Search in Generative AIRAG Patterns and Vector Search in Generative AI
RAG Patterns and Vector Search in Generative AI
 
Anypoint Code Builder , Google Pub sub connector and MuleSoft RPA
Anypoint Code Builder , Google Pub sub connector and MuleSoft RPAAnypoint Code Builder , Google Pub sub connector and MuleSoft RPA
Anypoint Code Builder , Google Pub sub connector and MuleSoft RPA
 
9 Steps For Building Winning Founding Team
9 Steps For Building Winning Founding Team9 Steps For Building Winning Founding Team
9 Steps For Building Winning Founding Team
 
NIST Cybersecurity Framework (CSF) 2.0 Workshop
NIST Cybersecurity Framework (CSF) 2.0 WorkshopNIST Cybersecurity Framework (CSF) 2.0 Workshop
NIST Cybersecurity Framework (CSF) 2.0 Workshop
 

Lecture 5 numbers and built in functions