finished parser.py's early version