Define bitwise-and operator, C/C++ Programming

Assignment Help:

Define Bitwise-AND Operator: &:?

The bitwise-AND operator (&) compares every bit of its first operand to the corresponding bit of its second operand. If both bits are 1 the matching result bit is set to 1. or else the corresponding result bit is set to 0.

x

y

x & y

0

0

0

0

1

0

1

0

0

1

1

1

In the following instance the bitwise-AND operator (&) contrast the bits of two integers nNumA and nNumB:

// Example of the bitwise-AND operator

int nNumA=1, nNumB=3, nNumC; // 00000001, 00000011
nNumC = nNumA & nNumB; // nNumC is now 1


Related Discussions:- Define bitwise-and operator

Program to open a file in c++, Program to Open a file in C++: int main...

Program to Open a file in C++: int main() {                  char ch;                  ifstream f1 ("OLDFILE.TXT");                  ofstream f2 ("NEWFILE.TXT");

I need cryengine sandbox speedometer and tachometer, I need Cryengine Sandb...

I need Cryengine Sandbox Speedometer and Tachometer We want to get working Tachometer and Speedometer for a car in latest Cryengine Sandbox. You will find how to make it usin

Illustrate the function definition, Illustrate the Function Definition? ...

Illustrate the Function Definition? The C code that explains what a function does is called the function definition. A function definition has the following form Type fun

There are ''''n'''' ants on a ''''n+1'''' leng n, There are ''''n'''' ants ...

There are ''''n'''' ants on a ''''n+1'''' length rod. The ants are numbered from 1 to n and are initially placed at positions starting from position 1 till position n. They are mov

I want vlc pitch changing addon, I want VLC Pitch Changing Addon Project...

I want VLC Pitch Changing Addon Project Description: Required: Plugin to modify the pitch of running tracks in VLC without changing the speed. Skills required are C Progra

HASH., Define hash functions. Explain the Division method, Mid square metho...

Define hash functions. Explain the Division method, Mid square method and Folding method of hash functions.

Described the order that objects in an array is destructed?, Described the ...

Described the order that objects in an array is destructed?

Explain multidimensional arrays, Multidimensional Arrays - Every dimens...

Multidimensional Arrays - Every dimension is specified in separate brackets e.g. int arr[4][3]; This is a two-dimensional array with 4 as row dimension and 3 as

If statement, Write a program to input two integers. If they are equal disp...

Write a program to input two integers. If they are equal display "The numbers are equal". Otherwise display a message if the first is a multiple of the second or if it is not a mul

Recursive function, Binomial coefficients are the numeric factors of the pr...

Binomial coefficients are the numeric factors of the products in a power of a binomial such as (x + y)n. For example, (x + y)2 = x2 + 2 x y + y2 has the coefficients 1 2 1. Binomia

Write Your Message!

Captcha
Free Assignment Quote

Assured A++ Grade

Get guaranteed satisfaction & time on delivery in every assignment order you paid with us! We ensure premium quality solution document along with free turntin report!

All rights reserved! Copyrights ©2019-2020 ExpertsMind IT Educational Pvt Ltd