added some stuff to the beginning of main