## find longest increasing subsequence using recursion

write a recursive function to find longest increasing subsequence using recursion. For example if we have sequence of { 6, 3, 4, 5, 6, 9, 8 }. The longest...

## minesweeper uva 10189 solution

problem link minesweeper uva 10189 solution Technique to solve this problem As you may have already noticed, each square may have at most 8 adjacent squares. Let us...

## Find the number of fighting groups using dfs

There is battlefield where some different types of aliens are fighting to each other. The battlefield exists some where on different planet. A scientist is able to watch the...

## Longest Increasing Path in a Matrix

Given an integer matrix, find the length of the longest increasing path. From each cell, you can either move to four directions: left, right, up or down. You may...

## UVA 929 Number Maze Dijkstra based problem

UVA 929 Number Maze Dijkstra based problem. We have already discussed Dijkstra algorithm for shortest path from source to destination here http://wikistack.com/shortest-path-problem-dijkstras-algorithm/. The given problem at this link https://uva.onlinejudge.org/index.php?option=onlinejudge&page=show_problem&problem=870...

## Find longest cycle in directed graph

Find longest cycle in directed graph. A cycle is a close path in graph. For example below given directed graph contains a cycle of maximum length of 5 starting...

## snake and ladder problem solution using BFS

Snake and Ladder problem solution using BFS (breadth first search). The problem is to find the minimum number of dice throws or minimum move to reach to the top...

## Check whether partially filled sudoku is valid

Write c or c++ program to check whether partially filled sudoku is valid. The given grid size is 9×9, divided into 9 regions of 3×3. Each row must contain...

## c program to check line segment intersection

write a c program to check line segment intersection. we have already discussed the line segment intersection theory on our previous post http://wikistack.com/line-segment-intersection/. Now we know how to make...

## maximum submatrix sum problem

Given a 2D matrix find the maximum submatrix sum in it. The matrix is containing positive and negative integers. For example The maximum submatrix sum is 15 in the...