- Generally, the performance factors of a program
- Code Algorithims
 - Languages + compilers
 - Processer (CPU) speed + Memory β how fast instruction will be executed
 - I/O and number of CPU cores
 
 - How we can determine the performance of an algorithm.
 - Or compare algorithms and determine which one is better ?
 - first, we need to determine what we mean of "better"
 
Experimental analysis
Algorithms performance
- time complexity β the time it takes to execute
 - space complexity β the memory it needs to execute
 - We will focus on time complexity right now
 
There are 2 ways to compare the complexity of algorithims
- Experimental analysis β compare the running time (benchmarking)
- inputs β array or objects or any data
 
 - Theoretical analysis β analyze the algorithms independently of the implementation (software or hardware)
 
    
Top comments (0)