A Simple Server

The task is to construct a simple server which just passes a string to the client. Client/server describes the relationship between two computer programs in whi...

Subset Sum Problem (Part II)

Given a set of numbers,our task is to find the number of subsets that sum to a particular value. Example- Set of numbers- {1,3,2,5,4,9} Sum=9 Subsets that sum t...

Subset Sum Problem

Given a set of positive integers and a value sum,the task is to find if there is a subset with sum equal to the given value. Example- Given set of numbers- {3,3...

Linked list is one of the fundamental,simplest and most common data structures in C programming language.A linked list is a data structure consisting of a group...

Path Finding

Given an undirected,unweighted graph and two vertices u and v,the task is to find the path between these two vertices.u can be considered as the source vertex a...

Longest path in a tree

Given an unweighted and undirected tree,the task is to find the length of the longest path (from one node to another) in that tree.The length of a path in this ...

Applications of DFS

One of the applications of DFS is to find the number of connected components in a graph.In graph theory, a connected component of an undirected graph is a sub-g...

Longest Common Subsequence

Given two sequences,the task is to find the length of longest sub-sequence present in both of them. A sub-sequence is a sequence that appears in the same relati...

Activity Selection Problem

Activity selection problem is an example of greedy algorithm.Greedy algorithms look for simple, easy-to-implement solutions to complex, multi-step problems by d...

Dijkstra’s Algorithm

Given a network of cities and the distances between them,the task is to find the shortest path from a city(source) to all other cities connected to it.The netwo...