Let's consider a binary number 01011000
Now, we will first find out the 1's complement of 01011000 then add 1 to get the 2's complement of the considered binary number.
Here is the process :
01011000
+1
Let's consider a binary number 01011000