I remember discussions about this and the consensus was that flour and water will leave little flour balls in any and all hair that are nearly impossible to get out.
Tangentially, you can make a slime by boiling water and stirring in a flour solution. Or, fry flour in oil for a minute and then whisk in water - that's how the French thicken up a sauce.
On the subject of cuisine, those little balls are used am to make seitan (mock duck). It's pure gluten, hence it being a nightmare to get out of hair!
If you give your hair a coat of another mess first, you won't get the little balls Pie Princess and I just used flour and water last weekend and we coated our hair in conditioner first. with literally not one flour ball stuck in our hair.