Moved arguments functions from main