in reply to How could I check if substring is not included in string ?

Read the documentation for index, it returns -1 on failure to find the substring.

So the comparison should be index(...) == -1

Btw Perl 6 makes this more intuitive by introducing a different boolean context, so that index can return a StrPos object that's true even if the substring was found at position 0. (Yes, Perl 5 could also make it return "0 but True", but "-1 but False" doesn't work).