In a lot competitive programming websites and books I've seen questions and solutions in which bitmasking has been used, for eg in many Dynamic Programming and Complete Search problems. I thought they'd be preferred over arrays of bools because they are more lightweight as they take only 1 bit per value as compared to 1 byte per value in array of bools.
However when I got to know about bitsets I wondered why bitmasks are used as bitsets also take same amount of memory, i.e 1 bit per value. But they have the added advantage that they are easier to use and manage. And now I'm confused regarding this.
So TL; DR why are bitmasks preffered over bitsets, especially in the context of Competitive Programming? To give an idea, here is a question that requires dynamic programming and bitmasking, and has a somewhat complicated (at least for me at my level, I'm only a 10th grader) solution that I saw in the editorial. https://www.hackerrank.com/challenges/synchronous-shopping
Thanks for answering my queries in advance!
Edit: Regarding the hateful comments about competitive programming, if you believe it's malpractice to use bitmasks, please try converting the code in the editorial of the problem link above to use bitsets and get an AC verdict.