Showing posts from January, 2019
Implementation of A* Algorithm #include<iostream> using namespace std; struct node { bool visited; int hue,num; char value; int dist[10]; struct node *child[10]; }; struct node *l[20],*open[20]; int oindex=0,kids; node *search(cha…
Implementation of Best First Search #include<iostream> #include<cstdlib> using namespace std; char goal; void create(); void dfs(); void bfs(); struct node { bool visited; int h; char value; int nu…
Depth First Search and Breadth First Search using C++ #include<iostream> #include<stdlib.h> using namespace std; char goal; void create(); void dfs(); void bfs(); struct node { char data; int status; struct no…