modified code, added constants
Merge pull request #2 from hephcero/leap

modified code, added constants