added attributes and dist() on Term.py