Preliminary main method for console