bryank has asked for the wisdom of the Perl Monks concerning the following question:
I'm looking for a process where I can:
1. look at each node (parent or child), and append a unique identifier if that node name exists already elsewhere.
2. The exception being that a parent node should have all its children assigned to it!
The input file is ordered in the way that the automation script would build the tree, so it is apparent which children go with with parents.
For example (and this is just to show the behavior)
Root:For Her For Her:Clothes -- Clothes would be marked as a child For Her:Pants -- Pants would be marked as a child For Her:Shirts -- Shirts would be marked as a child . . . Scarves:For Her -- 'For Her' is new, and should be unique. Root:Clothes -- 'Clothes' here is new, and should be unique
Any tips would be much appreciated!!
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: Creating tree with unique categories out of parent-child pointer list
by ikegami (Patriarch) on Jun 17, 2009 at 01:01 UTC | |
by bryank (Acolyte) on Jun 17, 2009 at 15:16 UTC | |
by ikegami (Patriarch) on Jun 17, 2009 at 15:47 UTC |