Bit Magic C/C++ Programs

  • Last Updated : 06 May, 2017

GeeksforGeeks - Summer Carnival Banner

C/C++ Program for Next Power of 2
C/C++ Program for Write an Efficient Method to Check if a Number is Multiple of 3
C/C++ Program for Write a C program to find the parity of an unsigned integer
C/C++ Program for Efficient way to multiply with 7
C/C++ Program for Write one line C function to find whether a no is power of two
C/C++ Program for Position of rightmost set bit
C/C++ Program for Find the Number Occurring Odd Number of Times
C/C++ Program for Check for Integer Overflow
C/C++ Program for Little and Big Endian Mystery
C/C++ Program for Write an Efficient C Program to Reverse Bits of a Number
C/C++ Program for Count set bits in an integer
C/C++ Program for Count number of bits to be flipped to convert A to B
C/C++ Program for Find the two non-repeating elements in an array of repeating elements
C/C++ Program for Rotate bits of a number
C/C++ Program for Compute the minimum or maximum of two integers without branching
C/C++ Program for Compute modulus division by a power-of-2-number
C/C++ Program for Compute the integer absolute value (abs) without branching
C/C++ Program for Find whether a given number is a power of 4 or not
C/C++ Program for Turn off the rightmost set bit
C/C++ Program for Multiply a given Integer with 3.5
C/C++ Program for Add 1 to a given number
C/C++ Program for Optimization Techniques | Set 1 (Modulus)
C/C++ Program for Next higher number with same number of set bits
C/C++ Program for Program to count number of set bits in an (big) array
C/C++ Program for A Boolean Array Puzzle
C/C++ Program for Smallest of three integers without comparison operators
C/C++ Program for Add two numbers without using arithmetic operators
C/C++ Program for Swap bits in a given number
C/C++ Program for Count total set bits in all numbers from 1 to n
C/C++ Program for Detect if two integers have opposite signs
C/C++ Program for Find the element that appears once
C/C++ Program for Binary representation of a given number
C/C++ Program for Write your own strcmp that ignores cases
C/C++ Program for Add two bit strings
C/C++ Program for Swap all odd and even bits
C/C++ Program for Find position of the only set bit
C/C++ Program for Divide and Conquer | Set 4 (Karatsuba algorithm for fast multiplication)
C/C++ Program for How to swap two numbers without using a temporary variable?
C/C++ Program for Check if a number is multiple of 9 using bitwise operators

My Personal Notes arrow_drop_up


Writing code in comment? Please use ide.geeksforgeeks.org, generate link and share the link here.