1 byte = 8 bits
So, does this mean 1 byte can only hold one character? E.g.:
"16" uses 2 bytes , "9" uses 1 byte , "a" uses 1 byte, "b" uses 1 byte
and if tiny int
has range of 0-255, does this mean it can be stored with 255 char?
what is storage of
1. tiny int (1)
2. tiny int (2)
what will be the range 0-10
1 byte may hold 1 character. For Example: Refer Ascii values for each character & convert into binary. This is how it works.
value 255 is stored as (11111111) base 2. Visit this link for knowing more about binary conversion. http://acc6.its.brooklyn.cuny.edu/~gurwitz/core5/nav2tool.html
Size of Tiny Int = 1 Byte ( -128 to 127)
Int = 4 Bytes (-2147483648 to 2147483647)