If only just for cooking purposes, in a perfect world I would have already invested in solar power in my home, and/or stocked up on panels and a small or even portable setup. you can buy the necessary panels/converters/batteries for a relatively small amount of money and most laymen could set them up fairly easily. Then you have at least a small amount of electricity to power a single induction burner like this. So cooking could be covered if you're willing to drop the cash to prepare in advance. Heating in an apartment could be replaced by extra insulation, especially if you aren't alone in there and have already set up any sort of fortifications. and even if you had a small handheld solar charger for a phone, you could have a flashlight indefinitely. So most electricity issues could be covered with planning in advance.
As for water, it depends more heavily on where you are. I'm lucky enough to have a well, so I just need to install a hand pump when SHTF and I have virtually unlimited clean water. If you're not that lucky, I think the only way to get water other than scavenging is to set up rain catchment on the roof of your building and start doing a rain dance.