increased debugging sample
refactored parser, using generator and reducing some duplication