$Remark:$

One arithmetic shift to left multiplies the number by 2, but we lose left most bits one by one

** **(AshiftL#2, R0)

Answer is (A).

PS: Arithmetic shift to left is same as Logical shift to left.

The Gateway to Computer Science Excellence

+53 votes

Best answer

Multiplication can be directly carried in 2's complement form. F87B = 1111 1000 0111 1011 can be left shifted 3 times to give 8P = 1100 0011 1101 1000 = C3D8.

Or, we can do as follows:

MSB in (F87B) is 1. So, P is a negative number. So, P = -1 * 2's complement of (F87B) = -1 * (0785) = -1 * (0000 0111 1000 0101)

8 * P = -1 * (0011 1100 0010 1000) (P in binary left shifted 3 times)

In 2's complement representation , this equals, 1100 0011 1101 1000 = C3D8

Correct Answer: $A$

Or, we can do as follows:

MSB in (F87B) is 1. So, P is a negative number. So, P = -1 * 2's complement of (F87B) = -1 * (0785) = -1 * (0000 0111 1000 0101)

8 * P = -1 * (0011 1100 0010 1000) (P in binary left shifted 3 times)

In 2's complement representation , this equals, 1100 0011 1101 1000 = C3D8

Correct Answer: $A$

+16

Left shift means adding a 0 at right end, which is equivalent to multiply by 2 in binary. Right shift will be doing division by 2.

+20

@Puja you can do it (10*P = 8*P + 2*P) where (8*P) you shift 3 digit left and then for (2*P) you can shift it 1 digit left and then add it.

+1

@hem chandra

Left shift is equal to multiplication and right shift equals to division in binary numbers, for the factor of 2 like 2 , 2^2, 2^3 .............

Since here it is 8 , it is 2^3. So we need to shift 3 times

Left shift is equal to multiplication and right shift equals to division in binary numbers, for the factor of 2 like 2 , 2^2, 2^3 .............

Since here it is 8 , it is 2^3. So we need to shift 3 times

0

@krishn.jh It won't be overflow because for overflow $C_{in} \neq C_{out}$ but here $C_{in} = C_{out} = 1$

0

It will be end carry, which is discarded in 2's complement.

And in 2's complement we can forget all 1s in MSBs, except one 1.

Eg. 111011 = 1011

Thus, we can forget the end carry in our result of 8P+2P because sign(negative here) as well as value is still preserved.

And in 2's complement we can forget all 1s in MSBs, except one 1.

Eg. 111011 = 1011

Thus, we can forget the end carry in our result of 8P+2P because sign(negative here) as well as value is still preserved.

0

@Akhilesh ok yes i know as concept says preceding 1's does not affect the values in 2's Complement as they make one partial block.

i got it as after discarding the carry 1, it is not going to affect the final result.

But Be careful as if sum is 0 carry 1 in MSB place then surely there would be Overflow.

i got it as after discarding the carry 1, it is not going to affect the final result.

But Be careful as if sum is 0 carry 1 in MSB place then surely there would be Overflow.

- All categories
- General Aptitude 1.9k
- Engineering Mathematics 7.5k
- Digital Logic 2.9k
- Programming and DS 4.9k
- Algorithms 4.4k
- Theory of Computation 6.2k
- Compiler Design 2.1k
- Databases 4.1k
- CO and Architecture 3.4k
- Computer Networks 4.2k
- Non GATE 1.4k
- Others 1.4k
- Admissions 595
- Exam Queries 573
- Tier 1 Placement Questions 23
- Job Queries 72
- Projects 18

50,737 questions

57,322 answers

198,393 comments

105,143 users