Modified string splitting so that there can be a white space as the last element (crucial in e.g. tab-delimited files)