my @p = (0..10); my @q = (1..9); if ( ( () = @p[0,1,2] ) == ( () = @q[3,6,1] ) ) { print "p slice == q slice\n" }