Sei sulla pagina 1di 3

1. Bubble sort – complexity – worst case O(n*n).

Best case O(n) when data is sorted

The first loop will run on ‘i’ from 0 to n-1.


The second loop will run on ‘j’ from 0 to n-i-1
2.Selection sort

– complexity – worst case O(n*n).

3.Insertion sort

– complexity – worst case O(n*n).


4.Merge sort

Complexity-=-

Linked list:

Time Complexity: O(n) where n is the length of linked list

Linkedlist Advantages over arrays

The biggest benefit of linked lists is that you do not specify a fixed size
for your list. The more elements you add to the chain, the bigger the chain
gets.
1) Dynamic size
2) Ease of insertion/deletion

Some 7 sets are there in the following link, just have a look at these

https://www.geeksforgeeks.org/practice-questions-for-recursion/

and lastly

pointers and dereferencing:

Typecasting-

alloc,malloc,calloc( very very imp)

Some tutorials can have a just glance -https://www.indiabix.com/online-test/c-programming-


test/rated

mutex and semaphore questions also😊

Potrebbero piacerti anche