Is it better to buy a bike that comes with puncture resistant tires, or get a cheaper bike that comes with worse tires and then get them replaced?
Don't decide your bike based on the stock tires. Tires are consumable components, and will not last like the rest of the components will. Tires are cheap, changing the frame or drivetrain is expensive.
Just ride the stock tires until they are worn out, then replace them with the puncture resistant tires, if by that point they are still important to you.
Many shops will swap out various components as part of a purchase anyway, so you can have your cake and eat it too.
You can get puncture resistant inner tubes, liners, or just squeeze a bunch of Slime into the current inners. Or not worry about it, keep your tires properly inflated, and be a happy camper.
Either way from my experience whether you spend the money up front or afterward puncture resistant tubes and tires are worth the expense. I have purchased mine aftermarket, and they added so many miles, and trips it's unreal. Let's face it changing tires and fixing flats is a hassle and I was having one once a week or around every 100 miles, until I changed to thicker tires. So in my case I say tires may not be the most expensive component but they effect the overall biking experience greatly. Good luck buying!