in reply to Re: Select randomly from a hash
in thread Select randomly from a hash
The keys of %verbs are "jumped" and "killed". The values associated with those keys are "eat" and undef.
The keys of %pronouns are "I", and "He". The values associated with those keys are "You" and "She".
So you're shuffling two pronouns, not four, and two verbs, not four. So the only possible pronouns, given your code, will be "I" and "He". "She" and "You" will never be selected. Bummer for you and her. ;)
And with your code (assuming you fixed the missing List::Utils, and uneven key/value pairs), the only actions that He and I could perform would be jumped and killed. ...we would never eat.
Dave
|
|---|