|Think about Loose Coupling|
RFC: Playing with globby Lady_Aleena (Curate)
|on Sep 15, 2015 at 19:25 UTC||Need Help??|
Lady_Aleena has asked for the
wisdom of the Perl Monks concerning the following question:
Several weeks ago I was playing around with glob's ability to create lists from stringified lists. (The forth paragraph in the doc.) I at first wanted to see if I could feed it arrays directly, but I was shown by jeffa the lists had to be comma separated strings. After playing around with it for a few minutes, I thought about finding a way use arrays, so wrote the following.
Note: I do not like the name of the subroutine, so I am open to suggestions.
Here are some sample arrays and how they would look once glob has done its work.
I have yet to figure out how to make this more interesting by including a pattern or a single joiner. From the above output, instead of plain green west 2 having green sector west tower 2nd floor or something akin to it. I could pre-munge the lists, but adding the ability to use a pattern would be nice too.
So, I would like a new name for the subroutine and maybe some pointers on how to add in a pattern to this. Also, maybe a few good reasons to use this I may not be seeing other than making a list to use for random selection.
No matter how hysterical I get, my problems are not time sensitive. So, relax, have a cookie, and a very nice day!