Key Takeways

Type Size (in bytes) Min Max
bool 1 0 1
char 1 TBD TBD
short 2 -215 215-1
unsigned short 2 0 216-1
float 4 TBD TBD
int+ 4 -231 231-1
unsigned int 4 0 232-1
long+ 4 -231 231-1
unsigned long 4 0 232-1
long long 8 -263 263-1
unsigned long long 8 0 264-1

+ int and long have the same values in the table, but they are different types. We’ll come back to this in the future, but know this isn’t a mistake!

Video Addendum


  • Create memory tables for adder assignment from Lesson02. Make sure you use different inputs as test cases in this memory table.
  • Find two whole number values for which your calculator doesn’t work.
    • Can you change the code to make it work for those values? Why or why not?
    • Are there two more values for this new calculator doesn’t work? Why or why not?
  • What is 264? Try using an online calculator to check and then write it down by hand. That’s how large an unsigned long long can get!
  • For each of the following types, come up with 5 real world examples when you would use them. Write these down along with a sentance for each explaining why that type is appropriate.
    • bool
    • unsigned short
    • int
    • unsigned long long
  • Fill out the table until you can recognize the values off the tip of your tongue. NO CALCULATORS
Short hand Full Value

End of Assignment Checklist

  • I finished all the assignments.
  • I shared my assignments with others.
  • I provided feedback for assignments of at least 2 others.
  • I addressed the feedback from others and thanked them for the review.