Popularly known food sources of potassium (like banana and avocado) aren't super great in a pinch. Coconut water, or beverages like Electrolit / Pedialyte, do a better job. For your regular dietary intake, there are lots of foods better than banana and avocado at getting you the potassium you need.
This post brought to you by the fucking awful leg cramps I used to get when eating a low carb diet.