TopSort in Python?
duncan smith
buzzard at urubu.freeserve.co.uk
Sat Jan 19 11:30:41 EST 2008
Carl Banks wrote:
> On Jan 18, 7:01 pm, Paddy <paddy3... at googlemail.com> wrote:
>> On Jan 18, 9:47 pm, startec... at gmail.com wrote:> Tim,
>>
>>> Thanks for the topsort code. It would be useful in a project I'm
>>> working on. Can I use the code for free under public domain? Thanks!
>> When I needed one I didn't know the name. I'm curious, how did you
>> know to look for the topological sort algorithm by name?
>
> I spent quite a bit of time looking for this one myself. It was quite
> a stumper. Sometimes Google gets us in the habit of just firing
> random search terms when we ought to be thinking it out.
>
> After quite of bit of dead end searching--like a week--I stepped back,
> thought about what I was looking for. I wanted a sort of dependency
> system: A must happen before B. What other programs do that? make,
> of course. I looked at the documents for make and found the term
> "directed acyclic graph", and pretty much instantly knew I had it.
Searching for "precedence diagram" might throw up some relevant results;
but you've probably already discovered that. I have some basic
precedence diagram code (no warranty etc.) somewhere if anyone is
interested.
Duncan
More information about the Python-list
mailing list