my @array1 = qw(one two three); my @array2 = ("one" . $" . "two", "three"); if ("@array1" eq "@array2") { print 'They are the same', $/; # no, they are NOT }