更新时间:2021-07-16 12:35:23
封面
版权信息
Dedication
About Packt
Why subscribe?
Contributors
About the author
About the reviewer
Packt is searching for authors like you
Preface
Who this book is for
What this book covers
To get the most out of this book
Download the example code files
Download the color images
Conventions used
Get in touch
Reviews
Section 1: Fundamentals and Core Algorithms
Overview of Algorithms
What is an algorithm?
The phases of an algorithm
Specifying the logic of an algorithm
Understanding pseudocode
A practical example of pseudocode
Using snippets
Creating an execution plan
Introducing Python packages
Python packages
The SciPy ecosystem
Implementing Python via the Jupyter Notebook
Algorithm design techniques
The data dimension
Compute dimension
A practical example
Performance analysis
Space complexity analysis
Time complexity analysis
Estimating the performance
The best case
The worst case
The average case
Selecting an algorithm
Big O notation
Constant time (O(1)) complexity
Linear time (O(n)) complexity
Quadratic time (O(n2)) complexity
Logarithmic time (O(logn)) complexity
Validating an algorithm
Exact approximate and randomized algorithms
Explainability
Summary
Data Structures Used in Algorithms
Exploring data structures in Python
List
Using lists
Lambda functions
The range function
The time complexity of lists
Tuples
The time complexity of tuples
Dictionary
The time complexity of a dictionary
Sets
Time complexity analysis for sets
DataFrames
Terminologies of DataFrames
Creating a subset of a DataFrame
Column selection
Row selection
Matrix
Matrix operations
Exploring abstract data types
Vector
Stacks
The time complexity of stacks
Practical example
Queues
The basic idea behind the use of stacks and queues
Tree
Terminology
Types of trees
Practical examples
Sorting and Searching Algorithms
Introducing Sorting Algorithms
Swapping Variables in Python
Bubble Sort
Understanding the Logic Behind Bubble Sort
A Performance Analysis of Bubble Sort
Insertion Sort
Merge Sort
Shell Sort
A Performance Analysis of Shell Sort
Selection Sort
The performance of the selection sort algorithm
Choosing a sorting algorithm
Introduction to Searching Algorithms
Linear Search
The Performance of Linear Search