Yes but you will be subject to an excise tax equal to 10% of the amount distributed. I won't even go into how much money you just lost by not allowing it to mature to retirement.
Reasons money can be withdrawn from a 401k account are:
Purchase a residence
Prevent foreclosure
Medical expenses not covered by insurance
Funeral expenses
Payment of post-secondary education expenses
Home repairs due to a deductible casualty loss
Many plans also allow employees to take loans from their 401K to be repaid with after-tax funds at a pre-defined interest rate. You might want to check into this. The loan itself is not taxable income or subject to the 10% penalty as long as its paid back accordingly.
Also I would check into getting a student loan as interest rates are often times extremely low and most do not need to be paid back until after graduation. Mine had a starting interest rate of 3%. After graduation I refinanced it with another company offering only 1.99% over a 10 year period.

