I went through the best solution to the MAXCOUNT problem and found some lines that I did not understand.
Code Problem and Best Solution Submitted
While I was reading the code to observe this approach, I came across these lines at the top of the code:
#define isSet(n) flags[n>>5]&(1<<(n&31)) #define unset(n) flags[n>>5] &= ~(1<<(n&31)) #define set(n) flags[n>>5]|=(1<<(n&31))
I do not know what is the point of using these lines.Can someone explain these lines and why are they used?
, , . n → 5 32, 32 int, . ( 31 0b11111, , , - 32), , (1 < n n, , ).
0b11111
Unset uses ~, - , . set , .
set
, .
Source: https://habr.com/ru/post/1568543/More articles:Connecting to OrientDB from Python (options) - pythonHow to copy a folder and its contents (files / subdirectories) in Python using a platform-independent implementation - python-3.xHow to create a full-size navigation box Android 5 - androidWhen and why use macroC # define (x) instead of a function? - c ++How can I get generics in javadoc code block? - javaHow to include cross origin queries in compojure? - clojureHow to prevent bootstrap 3 (3.3.1) navbar-form from loading into a separate line on the mobile interface - cssaws opsworks multiple nodejs applications? - amazon-web-servicesBind or lock text to marker in Matplotlib - pythonCustom Meteor Registration Template - meteorAll Articles