in reply to Building an array, "stripes on a wall"

In Perl you don't need to explicitly define the array length as it dynamically allocates memory for the purpose on it's own. This is by far the best feature while working on arrays in Perl.

You can use the push(@stripe,$pieces) with each time you do he calculation of $wall_height/$stripe. Or you even may use the unshift(@stripe,$pieces) function, whichever suites you more.