Hmmm... a negative look-ahead looks backwards, isn't it? So I thought it should be the correct one. For example, in the string '12345.6789.0', the first split point should be after the 6, i.e. giving 1245.6 as first element. Hence my idea goes like this: To the *left* of the split point must be a period, followed by a digit. The regexp engine needs to look back, so I thought it is negative look-ahead. Did I misunderstand here the explanations in perlre?
In reply to Re^2: split on zero-length pattern
by rovf
in thread split on zero-length pattern
by rovf
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |