moved stuff out of global scope to main method