top button
Flag Notify
    Connect to us
      Site Registration

Site Registration

What is impact of signed numbers on the memory?

+5 votes
257 views
What is impact of signed numbers on the memory?
posted Dec 11, 2013 by Neeraj Pandey

Share this question
Facebook Share Button Twitter Share Button LinkedIn Share Button

1 Answer

0 votes

Sign of the number is the first bit of the storage allocated for that number. So you get one bit less for storing the number. For example if you are storing an 8-bit number, without sign, the range is 0-255. If you decide to store sign you get 7 bits for the number plus one bit for the sign. So the range is -128 to +127.

answer Jul 17, 2017 by Manikandan J
Similar Questions
+3 votes

A list contains a set of numbers, one number presents once and other numbers present even no. of times. Find out the number that occurs once in the list.

+5 votes

Example :
Let the list be {2,3,5} and Assume always 1 be included then

2th number is 2
3th number is 3
4th number is 4
5th number is 5
6th number is 6
7th number is 8
8th number is 9
9th number is 10
10th number is 12
11th number is 15 and so on...

+3 votes
main {
 int a;
 a = 10;
}

Here, when the memory will be allocated.
Compile/Run time? why ?

...