Download presentation

Presentation is loading. Please wait.

Published byKaylyn Schmitt Modified over 3 years ago

1
Extra notes Modified from Callan R (2003) Artificial Intelligence Palgrave ISBN 0-333-80136-9 pg 50-55

2
The graph

3
Psudeocode for BFS node current; queue toVisit; List alreadyVisited; put root node in toVisit; while toVisit is notEmpty current=first node in toVisit; remove first node in toVisit; if current==goal add current to alreadyVisited; return true; endif for each child node C of current add C to toVisit; endfor; add current to alreadyVisited; endwhile;

4
toVisitalreadyVisited A[] BCA CDEAB DEFGHABC EFGHIABCD FGHIJKABCDE GHIJKLMABCDEF HIJKLMABCDEFG IJKLMNABCDEFGH JKLMNOABCDEFGHI KLMNOABCDEFGHIJ LMNOABCDEFGHIJK MNOPABCDEFGHIJKL NOPQABCDEFGHIJKLM OPQABCDEFGHIJKLMN PQABCDEFGHIJKLMNO QABCDEFGHIJKLMNOP []ABCDEFGHIJKLMNOPQ

5
Psudeocode for DFS node current; stack toVisit; List alreadyVisited; put root node in toVisit; while toVisit is notEmpty current=first node in toVisit; remove first node in toVisit; if current==goal add current to alreadyVisited; return true; endif for each child node C of current add C to toVisit; endfor; add current to alreadyVisited; endwhile;

6
toVisitalreadyVisited A[] BCA DECAB IECABD OECABDI ECABDIO JKCABDIOE KCABDIOEJ CABDIOEJK FGHABDIOEJKC LMGHABDIOEJKCF PMGHABDIOEJKCFL MGHABDIOEJKCFLP QGHABDIOEJKCFLPM

Similar presentations

OK

Breadth First Search and Depth First Search. Greatest problem in Computer Science Has lead to a lot of new ideas and data structures Search engines before.

Breadth First Search and Depth First Search. Greatest problem in Computer Science Has lead to a lot of new ideas and data structures Search engines before.

© 2018 SlidePlayer.com Inc.

All rights reserved.

Ads by Google

Ppt on email etiquettes presentation tips Pdf to ppt online tool Ppt on sbi mutual fund Dsp ppt on dft Ppt on types of trees Ppt on electricity for class 10th math Viewer ppt online reader Ppt on panel discussion outline Ppt on tcp ip protocol tutorial Thin film transistor display ppt on tv