I am storing all my equipped guns using a bit flag, and was just wondering if it was possible to check how many numbers are contained in a bit flag.  e.g. :  13 would contain 1, 4, and 8  NOTE: I am new to bit flags so my question might not make too much sense or I might have used the wrong terminology, if so just let me know and I will be happy to change it.
2629
8 bits representing the number 7 look like this:  00000111   Three bits are set.     What are algorithms to determine the number of set bits in a 32-bit integer?
110729
Why do computers only use 0 and 1? Won't the addition of other numbers such as 2 or 3 speed up computers? Also, 2 and 3 can be used to shorten the bit-length of integers (2 and 3 can be used to end an integer, so that the number 1 only needs one two bits.)..  Why is binary computer more preferred?
32837
int temp = 0x5E; // in binary 0b1011110.   Is there such a way to check if bit 3 in temp is 1 or 0 without bit shifting and masking.  Just want to know if there is some built in function for this, or am I forced to write one myself.
9082
It looks as if the 10k-tools flagged post list is b0rken.  Next to the review link in the toolbar there is a flag counter showing there are 10 flags to be reviewed:    Clicking on that flag counter leads to an empty page:        The moment I visit that page (through clicking on the flags counter, or by going to the review queue first then clicking on Tools, selecting the flags tab if not already selected), the flags counter disappears from the toolbar:    but after a while (half an hour, an hour?) the flag count re-appears in the toolbar.  Either the counter is wrong (presumably taken from a Redis cache somewhere) or the 10k flag review page is falling over every time someone tries to load it.  This at first appeared to happen only on Meta, on Stack Overflow the flags page has plenty to review. However, there are now  on Stack Overflow.
16873
For the life of me, I can't remember how to set, delete, toggle or test a bit in a bitfield. Either I'm unsure or I mix them up because I rarely need these. So a "bit-cheat-sheet" would be nice to have.  For example:   flags = flags | FlagsEnum.Bit4;  // Set bit 4.   or  if ((flags &amp; FlagsEnum.Bit4)) == FlagsEnum.Bit4) // Is there a less verbose way?   Can you give examples of all the other common operations, preferably in C# syntax using a [Flags] enum?
89595
How many $0's$ are in the end of:  $$1^1 \cdot 2^2 \cdot 3^3 \cdot 4^4.... 99^{99}$$  The answer is supposed to be $1100$ but I have absolutely NO clue how to get there.  Any advice?
5627
I am trying to solve following problem but not able to find any way to proceed.  Let $S$ be a set having $n$ elements. Can we count about number of binary operations that can be defined on a set? Can we also count number of commutative binary operations defined on  $S$?  Thanks for the help and suggestions
60901
You have one penny, one nickel, one dime, and one quarter. How many different amounts of money can you make using one or more of these coins? Please help me! I'm having trouble! I'm having trouble I know the obvious ones like $5,10,25,1,15,26,36,16,\ldots$ Help? And I need to know the coin combinations too. I found $15$ different ones! Anyone who can find more??
38963
How many 4 digit numbers are there which contain not more than two different digits?  As usual, I will highlight my attempt:   I can have 9 numbers using only 1 digit, e.g. $1111, 2222, \dots 9999$ = 9 digits Using two digits out of 9 (excluding 0) (selected in $\,^{8}C_{2}$ ways), I can arrange them in $4!$ ways. Furthermore, I can use one digit out of the selected 2 once or thrice (e.g. $2111$ or $2221$)  or simply both digits 2 times (e.g. $2288$, $6677$). Hence I get: $$\,^{8}C_{2} \times \left(\frac{4!}{2!\times2!} + \frac{4!}{3! \times 1!}\times 2\right) = 392$$ Finally, I consider numbers with zeroes. With zero selected as a digit, I have 9 options for other digits. And using the same logic as in 2) I can have either 1 zero ($8880$), 2 zeroes (e.g. $8800$) or 3 zeroes in a number ($7000$). This gives me $$9\times \left( \frac{4!}{2!\times2!} + \frac{4!}{3!\times1!} + 1\right) = 99$$   the above 3 steps yield a total number of $9+392+99=500$  However, the answer i have with me is $576$.
21610
Update , but there appears to be no documentation out there. The change in flag weight caused by each flagging still missing. TL;DR: Flag weight is not very clear. Just telling the user how many flags got approved/rejected would increase the flagging behavior. Additionally, flag feedback could improve this even more. Question:  is shown on a User's profile as a number between 0 and 750, each user starts with 100. The problem is that after reaching 500, flag weight increases in a sub-linear fashion, and it becomes hard to tell how many flags were considered to be correct or incorrect. I find it easy to remember &quot;I am at 250&quot; and when I come back, discover &quot;I am at 280&quot;, so I had 3 flags approved. Nowadays, &quot;I am at 576.3529&quot;. When I view my profile tomorrow, I'll be at 577.1285 or something, but I won't know how many flags got approved, denied or were ignored.  Would &quot;10 flags approved, 3 flags denied, 2 flags pending&quot; not provide more useful information? Even if it's just a pop-up box (StackExchange seems to use span-title for that). Additionally, being able to see what flags were denied would provide feedback to the user that is flagging in a way not desired by the moderator(s), and improve the flagging quality.  Maybe we can click on the flag weight to see a page with all our flags, the status (approved/denied/pending), the moderator that reviewed the flag, and maybe a comment the moderator left to explain why the flag was denied?
79254
I have to figure out a way to count how many sequences are there s.t:   My alphabet is $1$ up to $49$. Each number that is chosen, is chosen only once. The sequence is $6$ digits long. The sequence is in increasing order.  e.g that is a valid sequence: $(1, 2, 40, 42, 43, 49)$  and this is not: $(1, 2, 40, 25, 25, 12)$   I know that for the first 3 rules the answer is: $\binom{49}{6}\cdot 6!$  How do I deal with the fourth?
108191
I was looking at a 10x10 multiplication table, and I decided to count the unique products. There are 42 out of a possible 100 numbers represented. I had to wonder, why 42? I counted the 58 non-listed numbers -- most of them are either primes >10 or multiples of those primes. I couldn't figure out a satisfying reason like that for 75, 84, 96 and 98. I feel like the number 42 should be calculable from the natural log of 100 and 10, or something, but I can't really figure it out.  Also, I counted the frequency of all the numbers represented. They all have either 1, 2, 3, or 4 instances. The six numbers that have only 1 instance are all squares -- those of 1, 5, 7, 8, 9, and 10. This makes sense -- squares don't fall into that 4x5 = 5x4 redundancy. The 23 numbers with 2 instances are kind of the default I guess. The four with 3 are the remaining squares -- 4, 9, 16, and 36. 4 and 9 make sense to me, as they are squares within the basic range of the times table, so they are hit by themselves, their square root, and 1. I'm having trouble accounting for why 16 and 36 have three representatives. I'm also having trouble seeing the pattern (or patterns) in the numbers with four representatives.  I ultimately want to find a way to, given a times table of any size, calculate whether a given number will appear, and how many times.  Also, I'm pretty sure that for times tables 7x7 and below, more than half of the possible numbers are represented on the table, but for times tables above 7x7, less than half are represented. Why is 7 the turning point?
50020
I am using counters to save positive integers, something like that:  \setcounter{mycoutervalue}{59}   Is there any limit in the value I can save in a counter, in this case mycountervalue? And what is the exact limit?  Thanks! I do not want to get an unexpected overflow.
22757
In my flagging summary under the statistics, there is 1 flag listed as "disputed".  This is the first time I've ever seen a disputed flag in my summary, so I'm just curious, what is a disputed flag? How would you even dispute a flag? Is this the same as voting a flag as invalid?
102603
I have been going through some old posts, flagging them as necessary. But I have noticed that the number of posts that I am able to flag is continually staying at ten. It seems that the new flagging system has messed this up.  I am able to keep flagging posts even after 10, so I know it isn't a UI bug. This is a very big problem, because I can flag infinitely many times. And I am pretty sure this isn't the intended behavior of the overlords This isn't because I am being awarded more flags. I flag more than 13 posts in 5 minutes, and I can keep going without restriction  Some of the flags were accepted, so now my number is up to 13. But it is still staying at 13
95680
How many bit string of lenght 28   having at least one consecutive 000? without consecutive 000?   I'm using ti nspire, can i do it with nCr function.  I tried to do it but i did not found a way.  thank you.  i saw this post :    and this one :   but it did not help me.
62259
I have a "3" currently in the number of flagged posts:    However, when I click on the number, the list is empty. On the side-bar of the list, I can see this here:    But again, on any of the linked lists, nothing is to be found.  Is this a "travel"-issue? Or site-wide? Is this only on my account or do others have the same issue?