Comments (5)
//static procedures:
Bitset operator&(Bitset&, Bitset&);
Bitset operator|(Bitset&, Bitset&);
Bitset operator~();
//constructors:
Bitset(Bitset&);
Will do.
unsigned long to_ulong();
This implementation allows direct access to the underlying data via the functions getBlock and setBlock. Is this needed? to_ulong only works for bitsets with <= 64 bits. I can implement it if it's needed.
Bitset(sizetype bits, unsigned long value);
Similiar to the function to_ulong, since we can set blocks directly via setBlock, is this needed?
Currently blocks are unsinged char based. It is probably better to change it to unsinged long altogether.
If this exact behavior is needed, i can implement it.
from sea.
Either change blocktype
to unsigned long
. This enables simple setting/getting of the first block and treat it as a number.
Or, if you want to keep the byte access, please implement the unsigned long
variants in addition.
from sea.
@1yay1 Note: operator~
is not a static procedure, it is a member of the Bitset class. I edited the description to fix this.
from sea.
Implemented the functions.
The default behavior of the copy constructor works correctly for this class, so no implementation is needed
from sea.
I have made some more adjustments to the bitset (included in #13).
from sea.
Related Issues (20)
- In-Place Initializable Arrays HOT 2
- bfs_test.cpp fails HOT 2
- Master Failed
- Import/Export to the DIMACS graph file format
- BFS_Test fails when using gcc compiler instead of CLang HOT 1
- Implement new space-efficient graph representation
- Implement improved rank/select structure
- Move to atleast c++17, better c++20
- Refactor to a header-only library
- Improve the doc comments. HOT 1
- Rank-Select
- Visualisation
- iterator_test.cpp fails HOT 12
- Linear Time DFS HOT 1
- g++ linker errors HOT 2
- Master is not up to date HOT 1
- Hierholzer's Algorithm
- Ignore external files from coverage results HOT 1
- Implement rvalue constructors, rvalue assignment and the move function for all container classes HOT 3
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from sea.