Flood prevention through vegetation works because plant roots hold soil in place, prevent erosion, and slow down water runoff. While both shrubs and trees on river banks help achieve this, shrubs generally have denser, more fibrous root systems that are particularly effective at binding soil particles together near the surface.