I wear a summer cycling cap under my helmet with the brim (usually) flipped up. Protects my head (shaved head) from the sun under the helmet and wicks the sweat away from my head.
Better, and more importantly more stylish than a skull cap under the helmet.
Ummm....wash it? Yeah, that happens when it starts getting crunchy.
I have a Gore water and windproof cap for those cold rainy days and another cap with ear covers for those cold dry days.