2078 5

BIT201 ยท 2078 ยท 5 marks

Explain big oh(O) notation with suitable example.

Explain big oh(O) notation with suitable example. [5]

Data Structures and AlgorithmsChapter 2: Algorithm Analysis and ComplexityBig O notation with examples

Big Oh notation (O) is used to describe the upper bound of an algorithm's running time or space complexity. It represents the worst-case scenario of an algorithm's growth rate. Formally, a function f(n) = O(g(n)) if and only if there exist positive constants c and nโ‚€ such that: f(n) โ‰ค c ยท g(n) fo...