How to implement recursive KnapSack Algorithm in C# with real life Example – Part2

KnapSack

As we talked about in the last article, we used the recursive approach of KnapSack and we have had 2 drawbacks. It is heavy in running time and it is not possible to track the index of removed items. In this part, we will take the Dynamic part approach which will improve running time and….

How to implement recursive KnapSack Algorithm in C# with real life Example – Part1

KnapSack

Imagine you have a little trolley with a maximum load of 200Kg (20000 gram), and you get one chance to transport rocks of different weights, each has a reward value from location A to location B, and you are not allowed to load more than 200Kg of rocks. You want to pick the most possible….

How to create own Search Engine in C# – Part 3

Search Engine in C#

Introduction As we demonstrate in second part of this article, we was able to improve search results, but we talked also on how to return suggestion to typo in searching. In this article I am going to use Levenshtein Distance Algorithm. Levenshtein Algorithm calculates the distance between 2 input strings. If we have 2 equal….

How to create own Search Engine in C# – Part 2

Search Engine in C#

Introduction As we demonstrate in first part of this article, searching big data in List will not be efficient, therefore we have several options to optimize our searching. One way is to use Dictionary or SortedDictionary. Both Data structures are Key and Value based and the lookup time for the Key for both Data structure….

How to create own Search Engine in C# – Part 1

Search Engine in C#

Introduction I was always curious how Search Engine works in general and was always considering how can I build my own personal Search Engine for own data source. Of course not trying to build a new Google search engine or re-inventing the wheel, but there is a good feeling you get when your curiosity is satisfied, especially….

How to make Shortest path in Grid using BFS in C#

Shortest Path, Breath First Search

Since I started at the university and learned about data structure, the Queue was (I assume many of you know what Queue is, it is a First-In-First-Out (FIFO) data structure) a very important topic that is used in many algorithmic solutions. When I ended university and started working for different businesses, I switch from Java….