If you shooting slow fire there won't be any difference between the 9mm and the 40 S&W. During rapid fire the 9mm is typically easier to control with all things being equal. If your generally new to shooting I would suggest getting a 9mm. Practice ammo will be cheaper and that will increase your accuracy more than any inherant accuracy difference.
9mm ammo for sale