can now deal with arrays
improved splitter (jonah's one liner!)