AI

Merge sort algorithm project

The main idea of merge sort is separate big problem to many small problem. Then separate small problem to smallest one so the program will be solve many smallest one and group it to a bigger one. Solved and group again and again. Finally the answer will be appear.
Merge sort is an O(n log n) with both best and worst case.

Merge sort algorithm
More

Kruskal’s Algorithm

This project show how to resolve the Kruskal’s Algorithm with the shortest path program

Kruskal's Algorithm Program More

Knapsack Problem

This project is a Knapsack Problem represent by the classic program. How much the max value that the bag can contain with the max weight.

Knapsack Problem More

Find Way Out

This project show how to find the way out of the map. Like a rat running on the hold to find the way out

Find Way Out Program More

8 Puzzle

The A* Algorithm represent by 8 Puzzle.

Modify the simple A* from
Different Distance = RouteCount + distToGoal
to
Different Distance = RouteCount + distToGoal – distToInitial

RouteCount = Cost to current state
distToGoal = Estimated cost between possible state with
coordinates (x1, y1) and goal state at (x2, y2)
|x1 – x2| + |y1 – y2|

distToInitial = Estimated cost between possible state with
coordinates (x1, y1) and initial state at (x2, y2)
|x1 – x2| + |y1 – y2|

8 Puzzle Program More

Double Linked List

This project show how to keep the object with double linked list

Double Linked List Example More

Dijkstra’s Algorithm

This project show the shortest path to the target.

Dijkstra's Map More

Coin Changing

This project show how to resolve the knapsack problem with the coin changing program

Coin Changing Knapsack Problem More