Can any implement it on following ?

101101

101101

The Gateway to Computer Science Excellence

+19 votes

Sign extension is a step in

- floating point multiplication
- signed $16$ bit integer addition
- arithmetic left shift
- converting a signed integer from one size to another

+2

in which size do you want change this ?

0110 i want to extend this to 8 bit

as it is sign o so positive number 00000110

if it will be like 1110 then its sign 1 so its -ve number in 1's complement number it will be 10000110... just shift sign bit to msb of extended form ...

and in 2's number representation it will 11111110 ... as 2's complement is weighted ..so simply write sign bit in all places from msb to extra bit in extended form

0110 i want to extend this to 8 bit

as it is sign o so positive number 00000110

if it will be like 1110 then its sign 1 so its -ve number in 1's complement number it will be 10000110... just shift sign bit to msb of extended form ...

and in 2's number representation it will 11111110 ... as 2's complement is weighted ..so simply write sign bit in all places from msb to extra bit in extended form

+22 votes

Best answer

0

@ rajoramanoj, only increasing the number of bits is not enough along with it we also have to maintain the sign of number.

- All categories
- General Aptitude 1.9k
- Engineering Mathematics 7.4k
- 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.1k
- Non GATE 1.4k
- Others 1.7k
- Admissions 595
- Exam Queries 576
- Tier 1 Placement Questions 23
- Job Queries 72
- Projects 17

50,666 questions

56,167 answers

193,838 comments

94,017 users