The Gateway to Computer Science Excellence

0 votes

How to calculate 1's complement for a binary number?

The 1's complement can be easily calculated by inverting the 0s & 1s of a given binary number.

How to calculate 2's complement for a binary number?

1. Find the one's complement by inverting 0s & 1s of a given binary number.

2. Add 1 to the one's complement provides the two's complement.

1.

10101110

1's complement. 01010001

2's complement 01010010

2.

10000001

1's complement 01111110

2's complement 01111111

3. 10000000

1's complement. 01111111

2's complement . 10000000

4. 00000001

1's complement. 11111110

2'scomplement . 11111111

5. 00000000

1's complement . 11111111

2's complement. 00000000

- 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,271 answers

198,135 comments

104,777 users