Two bugs.
in_list([','], ['a\\', 'b']) returns true. It should return false.
in_list([qw( 1 2 4 )], [qw( 1 2 3 4 )]) returns false. It should return true since the OP is searching for a subsequence, not a substring.
Update: My fix for the first bug was equally buggy. Removed.
In reply to Re^2: sublist of a list
by ikegami
in thread sublist of a list
by Anonymous Monk
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |