Final code for mini project

- made changes in main.c