added more examples
added support for constants and fixed a few problems