It's been a year, but I still don't get that abbreviated syntax. For example, today I found out that I can easily split strings at each point using
@foo=split(/\./,$bar);
But to split at whitespace I can use
@foo=split(" ",$bar);
Why is that and what does it mean? I really don't get it, why doesn't
@foo=split(".",$bar);
work? | [reply] [Watch: Dir/Any] [d/l] [select] |
| [reply] [Watch: Dir/Any] |
I read it more than twice, before. It says "However, this special treatment can be avoided by specifying the pattern / / instead of the string " " , thereby allowing only a single space character to be a separator."
To me that means that for one or more ".", "." should work as well, or is there something special about a "." compared to a " "?
| [reply] [Watch: Dir/Any] |