eeh... houses can be a money pit. shit starts breaking, then the next thing you know your ass deep in a hole you cant get out from. And god forbid if you CANT sell your place.
Buying a house is always a risk. The gamble you're taking here is whether or not the stuff that breaks will surpass what you <would have> paid in rent. Over 5 years it is very not likely that your costs will outweigh your rent, especially if you buy a CHEAP house as suggested.
5 years rent even at a piddly $500 a month is $30,000. Even if you bump that up to $750 (pretty reasonable if you shop around) thats $45,000 in rent. If you DID spend all that money to fix up your house, it could even add value to your sale price, whereas rent will go out the window.
The real difference here is you have a good chance to get your money back + some (especially if you are making those repairs), whereas with rent it is guaranteed out the door. Even if you can't sell it, you have other options such as renting it out.