Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/youssef-saaed/booleanarray
A C++ class for storing boolean values efficiently using a single bit instead of byte per value
https://github.com/youssef-saaed/booleanarray
bitwise-operators cpp memory-management open-source optimization
Last synced: 4 days ago
JSON representation
A C++ class for storing boolean values efficiently using a single bit instead of byte per value
- Host: GitHub
- URL: https://github.com/youssef-saaed/booleanarray
- Owner: youssef-saaed
- License: mit
- Created: 2024-01-04T08:51:28.000Z (about 1 year ago)
- Default Branch: main
- Last Pushed: 2024-02-28T20:33:36.000Z (11 months ago)
- Last Synced: 2024-02-28T21:39:20.621Z (11 months ago)
- Topics: bitwise-operators, cpp, memory-management, open-source, optimization
- Language: C++
- Homepage:
- Size: 27.3 KB
- Stars: 1
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# BooleanArray
A C++ class for storing boolean values efficiently using a single bit per value.
## Usage
Include the `BooleanArray.h` header file in your C++ project and use the `BooleanArray` class as follows:
```cpp
#include "BooleanArray.h"// Example Usage
int main() {
// Create a BooleanArray with a specified size
BooleanArray boolArray(100);// Set and get values
boolArray.set(5, true);
bool value = boolArray[5];
return 0;
}