Skip to content

simple dynamic bitset implementation for when boost is not an option

License

Notifications You must be signed in to change notification settings

tbellosta/dynBitset

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

14 Commits
 
 
 
 
 
 
 
 

Repository files navigation

dynBitset

Simple header-only dynamic bitset implementation for when boost is not an option and you don't have time to implement your own. Only includes the cmath, vector, climits and iostream headers.

Example:

    size_t n;
    
    /** get n somewhere **/
    ...
    
    /** bitset w/ dimension assigned at runtime **/
    dynBitset set(n);
    
    /** set each bit **/
    for (int iBit = 0; iBit < n; ++iBit) {
        set[iBit] = ...;
    }
    
    /** get last bit **/
    bool bitVal = set[--n];

About

simple dynamic bitset implementation for when boost is not an option

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages