http://www.perlmonks.org?node_id=1008499


in reply to How can one call the lowest value of an array by reference?

Please explain your criteria for "lowest value."

"Lowest value" is singular, but your narrative and requirements treat it as if it meant "the two lowest values (plural)."

So why not "three lowest"? ... or "four?"

P.S added:

And how if understanding a hash is "a little complicated to me" how did you manage to write

011: @array_element_pos{@values}=(0..$#values);
012: $i=$array_element_pos{$min};

You seem to be stuck at the same old stand (Re: How can one create a folder B in D drive and save results in a text file inside B using perl script?) -- presenting incoherent questions and, when you include code, doing so with samples that appear to be beyond your competence, cargo-culted in bits and pieces, or un-compilable.

Please, do yourself (and us) a favor, and get the basics right (yes, hashes are among those basics). You'll find that further learning comes easier.

  • Comment on Re: How can one call the lowest value of an array by reference?

Replies are listed 'Best First'.
Re^2: How can one call the lowest value of an array by reference?
by Anonymous Monk on Dec 13, 2012 at 01:09 UTC
    Homework! =)