$18,000 per year in your 401k, $5500 in an IRA, $3350 in an HSA. That's $26,850 right off the bat. All tax free. Then max out your student loans and save up for the down payment on a house. Then date and find a spouse with a similar mindset about money. You'll be able to retire (literally never do work you don't want to do ever again) in 15-20 years easily if you keep your spending under control.
If you max out your 401k contribution ($18,000 if you're under 50) you can also contribute to an IRA (Roth or traditional) but your contribution will not reduce your taxable income.
The two aren't related. If you max out a traditional 401k and your income is low enough that you can take the traditional IRA deduction as well. Though that deduction phases out by $71k/year, which in our field is relatively low.