in reply to Why are my numbers not numeric???

The beginning of your regex is: /^(\d+\s+)/, which says: match the beginning of the string, then some digits, then whitespace. But your string starts with a digit, then a dot.

Abigail

Replies are listed 'Best First'.
Re: Re: Why are my numbers not numeric???
by Anonymous Monk on Oct 09, 2003 at 16:17 UTC
    so does this mean that I can't pattern match numbers in a string like this - I should start out saving them all in an array? thanks!
      Uhm, no, that doesn't mean it. \d+ matches a string of digits. If you want to match different type of numbers (decimal numbers, integers, reals, etc), you need different regexes. See the FAQ, or Regexp::Common.

      Abigail