#!/usr/bin/perl -w use strict; my $x = 'test'; no strict 'refs'; my @x = $x->(); print "@x"; sub test { my @array =qw(a b c d); return @array }