Time and Space Complexity
Assymptotic Notations
- To get an idea of notations like Big-Oh, Omega and Theta, it is recommended to watch this video, by Abdul Bari.
Finding the time complexity
- You should be able to find out the time complexity of a given code snippet. You can watch this video for this.
Checking whether your solution will pass the time limits
- Go through this tutorial on hackerearth. You must be able to find out, if your solution is fast enough, to pass the time limit constraints.
tip
Approximately, 107-108 operations are performed in 1 second. Always use this information, to estimate whether your solution will be able to pass the time limits, before writing any code.