Wrapping script in "main" function