Deprecated removal

1. Removed `print` statements
2. removed deprecated `has_key`
3. removed `exec` to `exec()`