Variable creation and deletion

Added variable creation and deletion, fixed a small error in main file,
added .gitignore, fixed a potential memory leak, and other minor fixes