~~~ ๐‘ป๐’‰๐’† ๐‘บ๐’†๐’“๐’Š๐’†๐’” ๐’๐’‡ ๐‘ฉ๐’Š๐’ˆ ๐‘ถ ~~~๐‘ท๐’‚๐’“๐’• โ€“ ๐‘ฐ๐‘ฝ

Polynomial time complexity in algorithms causes tasks to become increasingly complex with each additional input, much like managing a family WhatsApp group. Joining the group is O(n), deciphering messages is O(n^2), and managing disputes is O(n^3). Nested loops and multiple operations on the entire dataset indicate polynomial time complexity, such as O(n^2) or O(n^3).

Read More ~~~ ๐‘ป๐’‰๐’† ๐‘บ๐’†๐’“๐’Š๐’†๐’” ๐’๐’‡ ๐‘ฉ๐’Š๐’ˆ ๐‘ถ ~~~๐‘ท๐’‚๐’“๐’• โ€“ ๐‘ฐ๐‘ฝ

~~~ ๐‘ป๐’‰๐’† ๐‘บ๐’†๐’“๐’Š๐’†๐’” ๐’๐’‡ ๐‘ฉ๐’Š๐’ˆ ๐‘ถ ~~~๐‘ท๐’‚๐’“๐’• – ๐‘ฐ๐‘ฐ๐‘ฐ

In a linear time scenario, the time taken to complete a task grows with the size of the input. Like avoiding pesky questions at a big family gathering, each relative must be checked before finding the relative of interest. Similarly, in algorithms, checking each element in a list one by one creates a linear relationship. As datasets grow, efficient algorithms become crucial.

Read More ~~~ ๐‘ป๐’‰๐’† ๐‘บ๐’†๐’“๐’Š๐’†๐’” ๐’๐’‡ ๐‘ฉ๐’Š๐’ˆ ๐‘ถ ~~~๐‘ท๐’‚๐’“๐’• – ๐‘ฐ๐‘ฐ๐‘ฐ

~~~ ๐‘ป๐’‰๐’† ๐‘บ๐’†๐’“๐’Š๐’†๐’” ๐’๐’‡ ๐‘ฉ๐’Š๐’ˆ ๐‘ถ ~~~๐‘ท๐’‚๐’“๐’• – ๐‘ฐ๐‘ฐ

O(logn) indicates logarithmic time complexity, where the algorithm’s efficiency grows as the problem size reduces. For instance, in a sorted list search, you progressively eliminate half the list at each step, akin to finding a word in a dictionary by halving the search space. Various examples illustrate logarithmic time complexity, emphasizing its efficiency for large datasets.

Read More ~~~ ๐‘ป๐’‰๐’† ๐‘บ๐’†๐’“๐’Š๐’†๐’” ๐’๐’‡ ๐‘ฉ๐’Š๐’ˆ ๐‘ถ ~~~๐‘ท๐’‚๐’“๐’• – ๐‘ฐ๐‘ฐ

~~~ ๐‘ป๐’‰๐’† ๐‘บ๐’†๐’“๐’Š๐’†๐’” ๐’๐’‡ ๐‘ฉ๐’Š๐’ˆ ๐‘ถ ~~~๐‘ท๐’‚๐’“๐’• – ๐‘ฐ

Big O Notation provides a way to describe how the performance of an algorithm changes with input size, offering a worst-case scenario. O(1) represents constant time, where the algorithm takes the same amount of time regardless of input size. Examples include accessing array elements by index, swapping numbers, and inserting nodes in a linked list.

Read More ~~~ ๐‘ป๐’‰๐’† ๐‘บ๐’†๐’“๐’Š๐’†๐’” ๐’๐’‡ ๐‘ฉ๐’Š๐’ˆ ๐‘ถ ~~~๐‘ท๐’‚๐’“๐’• – ๐‘ฐ

ย ๐€ ๐’๐ก๐จ๐ซ๐ญ ๐ฐ๐ซ๐ข๐ญ๐ž ๐ฎ๐ฉ ๐จ๐ง ๐ฉ๐ญ๐ก๐ซ๐ž๐š๐ ๐Ÿ๐ฎ๐ง๐œ๐ญ๐ข๐จ๐ง๐ฌ

The pthread library is vital for multithreaded programming in Linux. It provides functions for thread creation, deletion, and management, such as pthread_create, pthread_exit, pthread_self, pthread_join, pthread_detach, pthread_mutex_init, and more. These functions enable efficient utilization of system resources and enhanced program performance.

Read More ย ๐€ ๐’๐ก๐จ๐ซ๐ญ ๐ฐ๐ซ๐ข๐ญ๐ž ๐ฎ๐ฉ ๐จ๐ง ๐ฉ๐ญ๐ก๐ซ๐ž๐š๐ ๐Ÿ๐ฎ๐ง๐œ๐ญ๐ข๐จ๐ง๐ฌ

๐„๐ฑ๐ฉ๐ฅ๐จ๐ซ๐ข๐ง๐ ย ๐ญ๐ก๐ž ๐’๐ฒ๐ฌ๐ญ๐ž๐ฆ ๐œ๐š๐ฅ๐ฅ๐ฌ

To transition from user space to kernel space, system calls are essential for executing actions on the kernel’s behalf. One example is the use of dynamic memory allocators like malloc() and realloc(), which rely on system calls such as sbrk() and brk(). Additionally, system calls like system(), clone(), wait(), and rt_sigaction() play key roles in process management.

Read More ๐„๐ฑ๐ฉ๐ฅ๐จ๐ซ๐ข๐ง๐ ย ๐ญ๐ก๐ž ๐’๐ฒ๐ฌ๐ญ๐ž๐ฆ ๐œ๐š๐ฅ๐ฅ๐ฌ

FUN WITH POINTERS

Pointers!A confusing yet curious topic. What is a POINTER?Well, itโ€™s a variable that stores the address of another variable. We often get confused by the dual operation performed by the pointer.‘&‘ Operator is an address operator that gives the address of a particular variable.‘*‘ Operator is an indirection operator, that refers to the value pointed […]

Read More FUN WITH POINTERS

THE SIMPLICITY OF STACK

Stack, the most frequently used data structure. Stack, as the name suggests, keeps on stacking up the data one above the other. Consider an example of stacking up books in a box. The implementation of stack in your program is similar to that. Stack is often referred to as Last In First Out (LIFO). Why?ย  […]

Read More THE SIMPLICITY OF STACK