$two = 'test'; @three = ('test'); my @array = ('one', 'two', 'three'); foreach (@array) { if (@$_) { print "Array exists: $_\n"; } if ($$_) { print "Scalar exists: $_\n"; } } #### my @fruit = (); my @meat = (); my @dairy = (); open (FOOD, "./food.txt") while () { chomp; ($category, $item) = split(/\$/, $_); push(@{$category}, $item) if (@{$category}); }