Click here to Skip to main content
Rate this: bad
good
Please Sign up or sign in to vote.
See more: C++ C C#
Given matrix ,wanted to find all path traversal in c# OR any language
SUppose there is 4*4 matrix,
then if starting vertex is at point [0][0] then it can traverse to [0][1],[1][0],[1][1] all its adjacent but no vertex in a path can visit twice.
if from [0][0] it traverse to [1][1] further adjacent vertex where it can travel to are [0][0],[1][0],[2][0],[0][1],[2][1],[0][2],[1][2],[2][2] but it cannot traverse to [0][0] as it is already visited in particular path.
I want all such posible path which traverse all vertex from start of any vertex.
Posted 12-Mar-13 19:35pm
m_21816
Comments
Mohibur Rashid at 13-Mar-13 1:35am
   
Try backtracking
Richard MacCutchan at 13-Mar-13 6:41am
   
This is an algorithmic rather than coding question, which you should be able to figure out with pencil and paper.
zaphoed at 13-Mar-13 8:12am
   
did you try out boost graph library? it might provide just what you want.

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

  Print Answers RSS
0 OriginalGriff 6,569
1 Sergey Alexandrovich Kryukov 6,168
2 DamithSL 5,228
3 Manas Bhardwaj 4,717
4 Maciej Los 4,150


Advertise | Privacy | Mobile
Web03 | 2.8.1411022.1 | Last Updated 13 Mar 2013
Copyright © CodeProject, 1999-2014
All Rights Reserved. Terms of Service
Layout: fixed | fluid

CodeProject, 503-250 Ferrand Drive Toronto Ontario, M3C 3G8 Canada +1 416-849-8900 x 100