Algo Lec#3 PDF
Algo Lec#3 PDF
Algo Lec#3 PDF
ALGORITHM ANALYSIS
LECTURER: M: SOHAIB AJMAL
Algorithm
No. of inputs
No. of inputs
C1.g(n)
f(n)
Time
C2.g(n)
No. of inputs
• To analyze algorithms:
– First, we start to count the number of significant
operations in a particular solution to assess its
efficiency.
– Then, we will express the efficiency of algorithms
using growth functions.
A sequence of operations:
➔ Total Cost = c1 + c2