my @array = (17, $var, "a string"); # now you can access the element of the original list by using the array, e.g.: my $first_num = $array[0];