Buying property doesn't give you residence or citizenship. But it is unlikely you would be thrown out of the country in any event unless you did something illegal. The Egyptian government loves residents with dollars to spend
Egypt is not America. They won't toss you out. You can renew your tourist visa every year for 12 months. Don't worry.
But welcome to buy property if you have the cash.
P.S. You keep referring to "a house". Have you ever been to Egypt? We don't have "houses" per se. The closest thing to "a house" is what is known as a villa here. Is that what you want? Or would a flat (you might know this as an apartment or condo) be enough? In either case, it is difficult to give you a price as realestate varies here just like it does in the states. It depends on where you are buying, what you are buying and the amenities you'll have included in your purchase.