java memory management Memory Management in Java: Garbage Collection algorithms There are several strategies of Garbage Collection each of which is suitable fora particular use case. This is article we have explored some of the best Garbage Collection algorithms. Serial Garbage Collection, Parallel Garbage Collection, Concurrent Mark and Sweep and G1 garbage collection

game theory Sprague-Grundy Theorem and Game of Kayle Sprague Grundy function returns smallest non negative integer which is not in the given set. Explore the application of Sprague Grundy Theorem using a famous game of Kayle. Find the complexity and implementation of Sprague Grundy theorem and game of kayle.

game theory Nimber Arithmetic : A deeper dive in Nim Explore Nimber Arithmetic in Game theory and always win a game. Nimbers have two particular operations. nim-addition and nim-multiplication. the nimbers are know as Grundy Numbers. Explore applications in the Game of Nim and odd Knight of the round table problem.

game theory Exploring The Game of Nim Nim is a mathematical game of strategy in which two players take turns removing objects from distinct heaps. The key to the theory of the game is the binary digital sum of the heap sizes "exclusive or" (xor). It is called the nim-sum. Find implementations of winning strategy and applications

catalan number Catalan Numbers Catalan Numbers are one of the widest used and evident number patterns. They are named after the Belgian mathematician Eugène Charles Catalan. A sequence of natural numbers that occur in various counting problems. The Catalan numbers are: 1, 1, 2, 5, 14, 42, 132, 429, 1430, 4862, 16796, 58786,

convex hull Chan's Algorithm to find Convex Hull In computational geometry, Chan's algorithm, named after Timothy M. Chan, is an optimal output-sensitive algorithm to compute the convex hull of a set P of n points, in 2- or 3-dimensional space. The algorithm takes O(n log h) time, where h is the number of vertices of the output (the convex hull).

convex hull Graham Scan Algorithm to find Convex Hull Graham's Scan Algorithm is an efficient algorithm for finding the convex hull of a finite set of points in the plane with time complexity O(N log N). The algorithm finds all vertices of the convex hull ordered along its boundary. It uses a stack to detect and remove concavities in the boundary.

convex hull Gift Wrap Algorithm (Jarvis March Algorithm) to find Convex Hull Gift Wrap Algorithm ( Jarvis March Algorithm ) to find the convex hull of any given set of points. We start from the leftmost point (or point with minimum x coordinate value) and we keep wrapping points in a counterclockwise direction. Find pseudocode, implementations, complexity and questions

convex hull Divide and Conquer algorithm to find Convex Hull Divide and Conquer algorithm to find Convex Hull. The key idea is that is we have two convex hull then, they can be merged in linear time to get a convex hull of a larger set of points. It requires to find upper and lower tangent to the right and left convex hulls C1 and C2

java memory management Memory Management in Java: Mark Sweep Compact Copy algorithm The basic strategy to remove unreferenced objects to is identify the life objects and deleting all the remaining objects. This is divided into two phases: Mark and Sweep. Every Garbage Collection algorithm used in Java Virtual Machine starts by finding out all objects that are still alive.

sorting algorithm Merge Sort Algorithm Complexity Implementations Applications Discussions The merge sort is a comparison-based sorting algorithm based on divide and conquer strategy. It has a usual performance of Θ(nlogn). This algorithm works by dividing the

sorting algorithm Quick Sort Algorithm Complexity Implementations Optimizations Applications Discussions Quicksort algorithm is a comparison sort algorithm based on Divide and Conquer strategy. It has an average performance of Θ(n*log(n)) and is considered as

sorting algorithm Bogo sort Algorithm Complexity Implementations Discussions BogoSort also known as permutation sort, stupid sort, slow sort, shotgun sort or monkey sort is a particularly ineffective algorithm based on generate and test paradigm. The algorithm successively

sorting algorithm Bead Sort Algorithm Complexity Implementations Discussions Bead sort, also called gravity sort, is a natural sorting algorithm. Both digital and analog hardware implementations of bead sort can achieve a sorting time of O(n); however,

sorting algorithm Bubble Sort Bubble Sort is the simplest sorting algorithm that works by repeatedly swapping the adjacent elements if they are in wrong order. Implementations in Java, C++, C, Go, Swift, JavaScript and many more.

sorting algorithm Selection Sort Algorithm Complexity Implementations Applications Discussions The selection sort algorithm sorts an array by repeatedly finding the minimum element (considering ascending order) from unsorted part and putting it at the beginning. The good thing

search algorithm Exponential Search Algorithm Algorithm Complexity Implementations Applications Discussions Exponential search algorithm (also called doubling search, galloping search, Struzik search) is a search algorithm, created by Jon Bentley and Andrew Chi-Chih Yao in 1976, for searching sorted,

search algorithm Ternary Search Algorithm Algorithm Complexity Implementations Applications Discussions Ternary search is a divide-and-conquer search algorithm. It is mandatory for the array (in which you will search for an element) to be sorted before we begin the

search algorithm Jump Search Algorithm Algorithm Complexity Implementations Applications Discussions Jump Search is a searching algorithm for sorted arrays. The basic idea is to check fewer elements by jumping ahead by fixed steps or skipping some elements in

search algorithm Interpolation Search Algorithm Algorithm Complexity Implementations Optimizations Applications Discussions You stored 2GB of data in your computer and you successfully executed a search in a blink of an eye. Great! You may have used binary search

search algorithm Binary Search Algorithm Algorithm Complexity Implementations Optimizations Applications Discussions Binary Search algorithm is a search algorithm where the key idea is to reduce the size of search space by half in every iteration by exploiting a

search algorithm Linear Search algorithm Linear search is a search algorithm inspired by real-life events. Implementations are available in C, C++, Java, C#, Clojure, Go, Haskell, JavaScript, Kotlin, PHP, Ruby, Rust, Scala, Swift, Meta and Nim.