The Gateway to Computer Science Excellence
0 votes
1.3k views

What is the result of the following expression?

(1 & 2) + (3 & 4)

  1. 1
  2. 3
  3. 2
  4. 0
in Programming and DS by Veteran (105k points)
recategorized by | 1.3k views

1 Answer

+3 votes
Best answer

$\frac{\begin{matrix} &0 &0 &1 & (1)\\ \And& 0 &1 & 0 & (2) \end{matrix}}{\begin{matrix} \ \ \ \ & 0 &0 & 0 & (0) \end{matrix}}$               $\frac{\begin{matrix} &0 &1 &1 & (3)\\ \And& 1 &0 & 0 & (4) \end{matrix}}{\begin{matrix} \ \ \ \ & 0 &0 & 0 & (0) \end{matrix}}$

$\frac{\begin{matrix} &0 &0 &0 & (0)\\ + & 0 &0 & 0 & (0) \end{matrix}}{\begin{matrix} \ \ \ \ & 0 &0 & 0 & (0) \end{matrix}}$

( 1 & 2 )=0                      ( 3 & 4 )=0

( 1 & 2 )+( 3 & 4 )=0

Hence,Option(D)0 is the correct choice.

by Boss (41.2k points)
selected by
0
@LeenSharma,I hope the above operation is of bitwise operator. :)
Quick search syntax
tags tag:apple
author user:martin
title title:apple
content content:apple
exclude -tag:apple
force match +apple
views views:100
score score:10
answers answers:2
is accepted isaccepted:true
is closed isclosed:true
50,741 questions
57,251 answers
198,050 comments
104,677 users