Parser reimplemented using smart algorithm. Saves memory and time.
Initial code scratch added.