fixed bug in parse and example code