Interview Question

Summer Software Engineering Internship InterviewCulver City, CA


What is the difference between a signed and unsigned integer variable type?


Interview Answers

2 Answers


Signed can hold positive and negative numbers, unsigned numbers can only hold positive numbers (or 0)

Anonymous on

signed value ranges from (-Max_Val, Max_Val), while signed goes from (0, 2*Max_Val). Max_Val is the predefined maximum value for the specific data type. They both have the same range of 2*Max_Val

Anonymous on

Add Answers or Comments

To comment on this, Sign In or Sign Up.