I am viewing an XML file and viewing every line in the document:
while ($line = <$fh>) {
if ($line =~ /<title>/.../<\/title>/) {
}
}
I’m not sure what exactly happens with ..and .... Previously, when I used the double point operator .., I would get an error
Using the uninitialized value of $ _ according to the pattern (m //)
However, when I modify the template using the triple-point operator ..., the error no longer occurs, and the script works as intended.
I understand the differences in operators in general, but not in this context.
Any help explaining this would be greatly appreciated.
user1874611
source
share