in reply to
my $var = join('|',@array) not behaving
Square brackets  are for creating a reference to an anonymous array. Parens () construct a list which you can assign to an array.
You can read more at perldata and perlref
my @array = ( 1, "word", 2 );
my $print_string = join ('|', @array);
Parens () construct a list which you can assign to an array.
Nit: parens group a list. The list is already there, but the precedence of = and , are such that without parentheses, only the first element of the list gets assigned.
such that without parentheses, only the first element of the list gets assigned.
Since we're being picky about the language, the list being assigned only has one element, so it's odd to refer to its first element. The assignment is the first element of the larger list.
My savings account
My retirement account
Winning the lottery
A Post-scarcity economy
Retirement?! You'll have to pull the keyboard from my cold, dead hands
I'm independently wealthy
Results (141 votes),