Update main.cpp

Added in most updated code