SlideShare a Scribd company logo
Idea of Algorithmic Efficiency
Idea of Algorithmic Efficiency
Algorithm-
performance of Algorithm- depends on complexity/efficiency of
algorithm
Performance of algorithms depend on two factors:
Internal Factor
Time required to run
Space required to run
External Factor
Size of the input to the algorithm
Speed of the computer on which it is run
Quality of the compiler
Big O Notation-It is used to represent an algorithm’s growth rate.It
is a mathematical formula to best describe algorithm’s
performance.
(growth rate is O(N2)steps for an algorithm whose input size is N .
Guidelines for computing Complexity of
algorithm.
1. Select computational resource( time and memory)
2. Pay attention to loops or recursion, and identify size
of input.
3. Try to see different cases inside it. (best, worst,
average case) Takes maximum possible time to perform
Performs better than worst case but doesn’t
give best performance
Takes shortest possible time to perform.
Python algorithm efficency
Python algorithm efficency
Python algorithm efficency
Python algorithm efficency
Python algorithm efficency
Python algorithm efficency
Python algorithm efficency
Python algorithm efficency
Python algorithm efficency
Order to Determine Big-O notation for the following calculated complexity
1. A function has "constant" growth if its output does not change based on the input ‘n’ , or
have n0 ,111 and 100010001000 are constant.
2. A function has “logarithmic" growth if its output increases according to logarithmic expression. In this
case
log2(n) , n log2n , 3 log2 n ,log (n)
3. A function has "linear" growth if its output increases linearly with the size of its input i.e ‘n’. In this case
n,
3n, (3/2)n are linear.
4. A function has "polynomial" growth if its output increases according to a polynomial expression. In this
case, 3n2 , n3 are polynomial.
5.A function has "exponential" growth if its output increases according to an exponential expression. In this
case, 2n , (3/2)n are exponential.

More Related Content

What's hot (20)

PPT
Daa presentation 97
Garima Verma
 
PDF
Algorithmic problem solving
Prabhakaran V M
 
PPT
Amortized analysis
Dr Shashikant Athawale
 
PPTX
Pengenalan Algoritma
Ajeng Savitri
 
PPTX
Daa unit 1
Abhimanyu Mishra
 
PPT
Lecture01 algorithm analysis
Zara Nawaz
 
PDF
Lecture 2 role of algorithms in computing
jayavignesh86
 
PDF
Analysis and Algorithms: basic Introduction
ssuseraf8b2f
 
PPT
Fundamental of Algorithms
Dr Shashikant Athawale
 
PPTX
Semantical Cognitive Scheduling
igalshilman
 
PDF
Lecture 1 objective and course plan
jayavignesh86
 
PDF
Design & Analysis of Algorithms Lecture Notes
FellowBuddy.com
 
PPTX
Algorithm and Data Structures - Basic of IT Problem Solving
coolpie
 
PPT
Aad introduction
Mr SMAK
 
PPTX
Data structures algorithms basics
ayeshasafdar8
 
PPT
chapter 1
yatheesha
 
PPTX
Lec 2 algorithms efficiency complexity
Anaya Zafar
 
PDF
Fundamentals of data structures ellis horowitz & sartaj sahni
Hitesh Wagle
 
PPT
Algorithm Design Presentation
Kawsar Ahmed
 
DOC
Karner resource estimation for objectory projects
Ocho08
 
Daa presentation 97
Garima Verma
 
Algorithmic problem solving
Prabhakaran V M
 
Amortized analysis
Dr Shashikant Athawale
 
Pengenalan Algoritma
Ajeng Savitri
 
Daa unit 1
Abhimanyu Mishra
 
Lecture01 algorithm analysis
Zara Nawaz
 
Lecture 2 role of algorithms in computing
jayavignesh86
 
Analysis and Algorithms: basic Introduction
ssuseraf8b2f
 
Fundamental of Algorithms
Dr Shashikant Athawale
 
Semantical Cognitive Scheduling
igalshilman
 
Lecture 1 objective and course plan
jayavignesh86
 
Design & Analysis of Algorithms Lecture Notes
FellowBuddy.com
 
Algorithm and Data Structures - Basic of IT Problem Solving
coolpie
 
Aad introduction
Mr SMAK
 
Data structures algorithms basics
ayeshasafdar8
 
chapter 1
yatheesha
 
Lec 2 algorithms efficiency complexity
Anaya Zafar
 
Fundamentals of data structures ellis horowitz & sartaj sahni
Hitesh Wagle
 
Algorithm Design Presentation
Kawsar Ahmed
 
Karner resource estimation for objectory projects
Ocho08
 

Similar to Python algorithm efficency (20)

PDF
Performance Analysis,Time complexity, Asymptotic Notations
DrSMeenakshiSundaram1
 
PPT
02 order of growth
Hira Gul
 
PPT
3. analysis of algorithms efficiency.ppt
Suma Raj
 
PPTX
Data Structure Asymptotic Notations.pptx
MeenakshiGupta233101
 
PDF
Algorithm Analysis.pdf
MemMem25
 
PPT
CS8451 - Design and Analysis of Algorithms
Krishnan MuthuManickam
 
PDF
Ch24 efficient algorithms
rajatmay1992
 
PPTX
Algorithm for the DAA agscsnak javausmagagah
RaviPandey598038
 
PDF
Ch1. Analysis of Algorithms.pdf
zoric99
 
PDF
Analysis of Algorithms
Amna Saeed
 
PPS
Data Structures and Algorithms Unit 01
Prashanth Shivakumar
 
PDF
Algorithm chapter 2
chidabdu
 
PDF
Slides [DAA] Unit 2 Ch 2.pdf
Vijayraj799513
 
PPTX
Algorithm Analysis
Megha V
 
PPTX
Data Structures and Agorithm: DS 22 Analysis of Algorithm.pptx
RashidFaridChishti
 
PDF
Brief introduction to Algorithm analysis
Anantha Ramu
 
PPT
Introduction to design and analysis of algorithm
DevaKumari Vijay
 
PPTX
Time complexity.pptxghhhhhhhhhhhhhhhjjjjjjjjjjjjjjjjjjjjjjjjjj
shesnasuneer
 
PPTX
9 big o-notation
irdginfo
 
Performance Analysis,Time complexity, Asymptotic Notations
DrSMeenakshiSundaram1
 
02 order of growth
Hira Gul
 
3. analysis of algorithms efficiency.ppt
Suma Raj
 
Data Structure Asymptotic Notations.pptx
MeenakshiGupta233101
 
Algorithm Analysis.pdf
MemMem25
 
CS8451 - Design and Analysis of Algorithms
Krishnan MuthuManickam
 
Ch24 efficient algorithms
rajatmay1992
 
Algorithm for the DAA agscsnak javausmagagah
RaviPandey598038
 
Ch1. Analysis of Algorithms.pdf
zoric99
 
Analysis of Algorithms
Amna Saeed
 
Data Structures and Algorithms Unit 01
Prashanth Shivakumar
 
Algorithm chapter 2
chidabdu
 
Slides [DAA] Unit 2 Ch 2.pdf
Vijayraj799513
 
Algorithm Analysis
Megha V
 
Data Structures and Agorithm: DS 22 Analysis of Algorithm.pptx
RashidFaridChishti
 
Brief introduction to Algorithm analysis
Anantha Ramu
 
Introduction to design and analysis of algorithm
DevaKumari Vijay
 
Time complexity.pptxghhhhhhhhhhhhhhhjjjjjjjjjjjjjjjjjjjjjjjjjj
shesnasuneer
 
9 big o-notation
irdginfo
 
Ad

More from ToniyaP1 (6)

PDF
Numpy
ToniyaP1
 
PPTX
Data structures: linear lists
ToniyaP1
 
PPTX
Python library
ToniyaP1
 
PPTX
Python data file handling
ToniyaP1
 
PPTX
Python functions
ToniyaP1
 
PPTX
Python recursion
ToniyaP1
 
Numpy
ToniyaP1
 
Data structures: linear lists
ToniyaP1
 
Python library
ToniyaP1
 
Python data file handling
ToniyaP1
 
Python functions
ToniyaP1
 
Python recursion
ToniyaP1
 
Ad

Recently uploaded (20)

PPTX
How to Configure Refusal of Applicants in Odoo 18 Recruitment
Celine George
 
PPTX
Nitrogen rule, ring rule, mc lafferty.pptx
nbisen2001
 
PDF
AI-assisted IP-Design lecture from the MIPLM 2025
MIPLM
 
PPTX
Ward Management: Patient Care, Personnel, Equipment, and Environment.pptx
PRADEEP ABOTHU
 
PDF
I3PM Case study smart parking 2025 with uptoIP® and ABP
MIPLM
 
PPTX
Life and Career Skills Lesson 2.pptxProtective and Risk Factors of Late Adole...
ryangabrielcatalon40
 
PDF
TLE 8 QUARTER 1 MODULE WEEK 1 MATATAG CURRICULUM
denniseraya1997
 
PDF
Lesson 1 : Science and the Art of Geography Ecosystem
marvinnbustamante1
 
PDF
Indian National movement PPT by Simanchala Sarab, Covering The INC(Formation,...
Simanchala Sarab, BABed(ITEP Secondary stage) in History student at GNDU Amritsar
 
PDF
Andreas Schleicher_Teaching Compass_Education 2040.pdf
EduSkills OECD
 
PDF
TechSoup Microsoft Copilot Nonprofit Use Cases and Live Demo - 2025.06.25.pdf
TechSoup
 
PDF
CAD25 Gbadago and Fafa Presentation Revised-Aston Business School, UK.pdf
Kweku Zurek
 
PPTX
Marketing Management PPT Unit 1 and Unit 2.pptx
Sri Ramakrishna College of Arts and science
 
PDF
Quiz Night Live May 2025 - Intra Pragya Online General Quiz
Pragya - UEM Kolkata Quiz Club
 
PDF
Our Guide to the July 2025 USPS® Rate Change
Postal Advocate Inc.
 
PDF
Genomics Proteomics and Vaccines 1st Edition Guido Grandi (Editor)
kboqcyuw976
 
PDF
IMPORTANT GUIDELINES FOR M.Sc.ZOOLOGY DISSERTATION
raviralanaresh2
 
PPTX
Lesson 1 Cell (Structures, Functions, and Theory).pptx
marvinnbustamante1
 
PDF
I3PM Industry Case Study Siemens on Strategic and Value-Oriented IP Management
MIPLM
 
PPTX
grade 8 week 2 ict.pptx. matatag grade 7
VanessaTaberlo
 
How to Configure Refusal of Applicants in Odoo 18 Recruitment
Celine George
 
Nitrogen rule, ring rule, mc lafferty.pptx
nbisen2001
 
AI-assisted IP-Design lecture from the MIPLM 2025
MIPLM
 
Ward Management: Patient Care, Personnel, Equipment, and Environment.pptx
PRADEEP ABOTHU
 
I3PM Case study smart parking 2025 with uptoIP® and ABP
MIPLM
 
Life and Career Skills Lesson 2.pptxProtective and Risk Factors of Late Adole...
ryangabrielcatalon40
 
TLE 8 QUARTER 1 MODULE WEEK 1 MATATAG CURRICULUM
denniseraya1997
 
Lesson 1 : Science and the Art of Geography Ecosystem
marvinnbustamante1
 
Indian National movement PPT by Simanchala Sarab, Covering The INC(Formation,...
Simanchala Sarab, BABed(ITEP Secondary stage) in History student at GNDU Amritsar
 
Andreas Schleicher_Teaching Compass_Education 2040.pdf
EduSkills OECD
 
TechSoup Microsoft Copilot Nonprofit Use Cases and Live Demo - 2025.06.25.pdf
TechSoup
 
CAD25 Gbadago and Fafa Presentation Revised-Aston Business School, UK.pdf
Kweku Zurek
 
Marketing Management PPT Unit 1 and Unit 2.pptx
Sri Ramakrishna College of Arts and science
 
Quiz Night Live May 2025 - Intra Pragya Online General Quiz
Pragya - UEM Kolkata Quiz Club
 
Our Guide to the July 2025 USPS® Rate Change
Postal Advocate Inc.
 
Genomics Proteomics and Vaccines 1st Edition Guido Grandi (Editor)
kboqcyuw976
 
IMPORTANT GUIDELINES FOR M.Sc.ZOOLOGY DISSERTATION
raviralanaresh2
 
Lesson 1 Cell (Structures, Functions, and Theory).pptx
marvinnbustamante1
 
I3PM Industry Case Study Siemens on Strategic and Value-Oriented IP Management
MIPLM
 
grade 8 week 2 ict.pptx. matatag grade 7
VanessaTaberlo
 

Python algorithm efficency

  • 1. Idea of Algorithmic Efficiency
  • 2. Idea of Algorithmic Efficiency Algorithm- performance of Algorithm- depends on complexity/efficiency of algorithm Performance of algorithms depend on two factors: Internal Factor Time required to run Space required to run External Factor Size of the input to the algorithm Speed of the computer on which it is run Quality of the compiler Big O Notation-It is used to represent an algorithm’s growth rate.It is a mathematical formula to best describe algorithm’s performance. (growth rate is O(N2)steps for an algorithm whose input size is N .
  • 3. Guidelines for computing Complexity of algorithm. 1. Select computational resource( time and memory) 2. Pay attention to loops or recursion, and identify size of input. 3. Try to see different cases inside it. (best, worst, average case) Takes maximum possible time to perform Performs better than worst case but doesn’t give best performance Takes shortest possible time to perform.
  • 13. Order to Determine Big-O notation for the following calculated complexity 1. A function has "constant" growth if its output does not change based on the input ‘n’ , or have n0 ,111 and 100010001000 are constant. 2. A function has “logarithmic" growth if its output increases according to logarithmic expression. In this case log2(n) , n log2n , 3 log2 n ,log (n) 3. A function has "linear" growth if its output increases linearly with the size of its input i.e ‘n’. In this case n, 3n, (3/2)n are linear. 4. A function has "polynomial" growth if its output increases according to a polynomial expression. In this case, 3n2 , n3 are polynomial. 5.A function has "exponential" growth if its output increases according to an exponential expression. In this case, 2n , (3/2)n are exponential.