in reply to Re^2: Reading a file as an multi dimensional array Please help
in thread Reading a file as an multi dimensional array Please help
I think you might have misunderstood this paragraph from stiller's reply.
If some records miss data (...) in say the third column, your split will give you one element less for the line, rather than an array where the third element is undef, which is what you want.
Allow me to rephrase that:
If some records miss data (...) in say the third column, your split will give you one element less for the line, rather than what you want, which is an array where the third element is undef.
In other words, splitting on whitespace will cause problems if any column lacks data. That's why stiller mentions trying to get your data in another format, and wfsp suggests unpack.
|
|---|