Professional Documents
Culture Documents
CS611 - Advanced Algorithms - Chapter 2 Slides - Part1
CS611 - Advanced Algorithms - Chapter 2 Slides - Part1
ALGORITHMS
CS 611
Chapter Two
Accurate
Concise
General
Easy to understand.
For example,
The size of an integer is the number of digits in its representation.
𝑛2
+ 106 𝑛
10
10 1/25/2024 Dr. E. Fadel
Asymptotic Notation
In summary,
Asymptotic Notations are languages that allow us to analyze an
algorithm's running time by identifying its behavior as the input
size for the algorithm increases. This is also known as an
algorithm's growth rate. (Khan Academy)
Procedure and function calls take constant time plus the time to
execute their body.
Note:
The statement “if C then I” is a shorthand for “if C then I
else ;” (an if–then–else with an empty “else” part).
Indentation is used to group statements.
Line break replace a semicolon for the purpose of
separating statements.
Note: the types “Set of Element” and “Sequence of Element” mentioned earlier are ordinary classes.