in reply to Re^2: printing unequal sized lists side by side
in thread printing unequal sized lists side by side

Instead of the ternary operator, might I recommend the "defined-or" test instead. It's more succinct and it doesn't fail on a value of '0'.

print $array1[$index] // ' ';