Loading practice questions
What will be the output of the following C++ code
#include
#include
using namespace std;
int main()
{
bitset<b1(95);
bitset<b2 = b1 << cout<<b}
Correct Answer: A — 00001101
Explanation:
^ operator is used to take xor of two bitset variables i.e. if ith bit in both varaibles are either 1 or 0 then answer is 0 otherwise answer is 1.