{"content":[{"text":"02 - Lecture - C language basics \n ---------------------------------","bbox":{"left":0.125817,"top":0.095556,"width":0.323529,"height":0.02965799999999999}},{"text":"Data types in C \n ----------------","bbox":{"left":0.125817,"top":0.151111,"width":0.15686300000000003,"height":0.02965900000000002}},{"text":"char <= short <=","bbox":{"left":0.125817,"top":0.192778,"width":0.15686299999999997,"height":0.015770000000000006}},{"text":"int <= long","bbox":{"left":0.292484,"top":0.192778,"width":0.10784299999999997,"height":0.015770000000000006}},{"text":"<= long long","bbox":{"left":0.410131,"top":0.192778,"width":0.11764699999999995,"height":0.015770000000000006}},{"text":"-","bbox":{"left":0.145425,"top":0.220556,"width":0.009804000000000007,"height":0.015770000000000006}},{"text":"C standard","bbox":{"left":0.165033,"top":0.220556,"width":0.09803899999999996,"height":0.015770000000000006}},{"text":"does not","bbox":{"left":0.272876,"top":0.220556,"width":0.07843099999999997,"height":0.015770000000000006}},{"text":"specify byte sizes","bbox":{"left":0.361111,"top":0.220556,"width":0.176471,"height":0.015770000000000006}},{"text":"of these","bbox":{"left":0.547386,"top":0.220556,"width":0.07843099999999992,"height":0.015770000000000006}},{"text":"types.","bbox":{"left":0.635621,"top":0.220556,"width":0.05882399999999999,"height":0.015770000000000006}},{"text":"-","bbox":{"left":0.145425,"top":0.248333,"width":0.009804000000000007,"height":0.01576999999999998}},{"text":"on most","bbox":{"left":0.165033,"top":0.248333,"width":0.068627,"height":0.01576999999999998}},{"text":"systems:","bbox":{"left":0.243464,"top":0.248333,"width":0.07843100000000003,"height":0.01576999999999998}},{"text":"char is 1","bbox":{"left":0.204248,"top":0.276111,"width":0.08823599999999995,"height":0.015770000000000006}},{"text":"byte, short is 2, int","bbox":{"left":0.302288,"top":0.276111,"width":0.205882,"height":0.015770000000000006}},{"text":"is","bbox":{"left":0.517974,"top":0.276111,"width":0.01960799999999996,"height":0.015770000000000006}},{"text":"4, long long","bbox":{"left":0.547386,"top":0.276111,"width":0.11764699999999995,"height":0.015770000000000006}},{"text":"is 8.","bbox":{"left":0.674837,"top":0.276111,"width":0.049018999999999924,"height":0.015770000000000006}},{"text":"-","bbox":{"left":0.145425,"top":0.303889,"width":0.009804000000000007,"height":0.015770000000000006}},{"text":"long is","bbox":{"left":0.165033,"top":0.303889,"width":0.06862699999999997,"height":0.015770000000000006}},{"text":"the problematic","bbox":{"left":0.243464,"top":0.303889,"width":0.14705899999999994,"height":0.015770000000000006}},{"text":"one:","bbox":{"left":0.400327,"top":0.303889,"width":0.03921600000000003,"height":0.015770000000000006}},{"text":"Most 32-bit systems and 64-bit \n 64-bit UNIX (such as our Linux \n Java:","bbox":{"left":0.204248,"top":0.331667,"width":0.294118,"height":0.043547}},{"text":"Windows: 4 \n system): 8 \n 8","bbox":{"left":0.50817,"top":0.331667,"width":0.09803899999999999,"height":0.043547}},{"text":"bytes \n bytes \n bytes","bbox":{"left":0.616013,"top":0.331667,"width":0.04901999999999995,"height":0.043547}},{"text":"-","bbox":{"left":0.145425,"top":0.387222,"width":0.009804000000000007,"height":0.015770000000000006}},{"text":"if you","bbox":{"left":0.165033,"top":0.387222,"width":0.058822999999999986,"height":0.015770000000000006}},{"text":"need to ensure byte","bbox":{"left":0.23366,"top":0.387222,"width":0.18627499999999994,"height":0.015770000000000006}},{"text":"sizes, use","bbox":{"left":0.429739,"top":0.387222,"width":0.09803899999999999,"height":0.015770000000000006}},{"text":"int<N>_t types:","bbox":{"left":0.537582,"top":0.387222,"width":0.14705899999999994,"height":0.015770000000000006}},{"text":"- int8_t, int16_t, int32_t, \n - #include <stdint.h> \n - defined in C99 standard","bbox":{"left":0.184641,"top":0.415,"width":0.264705,"height":0.04354800000000003}},{"text":"int64_t","bbox":{"left":0.45915,"top":0.415,"width":0.06862699999999994,"height":0.015770000000000006}},{"text":"-","bbox":{"left":0.145425,"top":0.470556,"width":0.009804000000000007,"height":0.015770000000000006}},{"text":"binary numbers","bbox":{"left":0.165033,"top":0.470556,"width":0.13725399999999996,"height":0.015770000000000006}},{"text":"and their","bbox":{"left":0.312092,"top":0.470556,"width":0.08823500000000001,"height":0.015770000000000006}},{"text":"hexadecimal","bbox":{"left":0.410131,"top":0.470556,"width":0.10784300000000002,"height":0.015770000000000006}},{"text":"representations","bbox":{"left":0.527778,"top":0.470556,"width":0.14705899999999994,"height":0.015770000000000006}},{"text":"Binary Dec \n 0000 0 \n 0001 1 \n 0010 2 \n 0011 3","bbox":{"left":0.194444,"top":0.498333,"width":0.09803999999999996,"height":0.07132599999999989}},{"text":"Hex \n 0 \n 1 \n 2 \n 3","bbox":{"left":0.302288,"top":0.498333,"width":0.029411999999999994,"height":0.07132599999999989}},{"text":"Binary Dec \n 1000 8 \n 1001 9 \n 1010 10 \n 1011 11","bbox":{"left":0.429739,"top":0.498333,"width":0.09803899999999999,"height":0.07132599999999989}},{"text":"Hex \n 8 \n 9 \n A \n B","bbox":{"left":0.537582,"top":0.498333,"width":0.029411999999999994,"height":0.07132599999999989}},{"text":"0100 \n 0101 \n 0110 \n 0111","bbox":{"left":0.204248,"top":0.581667,"width":0.039216,"height":0.05743599999999993}},{"text":"4 \n 5 \n 6 \n 7","bbox":{"left":0.272876,"top":0.581667,"width":0.00980399999999998,"height":0.05743599999999993}},{"text":"4 \n 5 \n 6 \n 7","bbox":{"left":0.312092,"top":0.581667,"width":0.00980399999999998,"height":0.05743599999999993}},{"text":"1100 \n 1101 \n 1110 \n 1111","bbox":{"left":0.439542,"top":0.581667,"width":0.03921600000000003,"height":0.05743599999999993}},{"text":"12 \n 13 \n 14 \n 15","bbox":{"left":0.498366,"top":0.581667,"width":0.01960799999999996,"height":0.05743599999999993}},{"text":"C \n D \n E \n F","bbox":{"left":0.547386,"top":0.581667,"width":0.009804000000000035,"height":0.05743599999999993}},{"text":"-","bbox":{"left":0.145425,"top":0.651111,"width":0.009804000000000007,"height":0.01576999999999995}},{"text":"two’s-complement encoding","bbox":{"left":0.165033,"top":0.651111,"width":0.24509699999999998,"height":0.01576999999999995}},{"text":"for representing","bbox":{"left":0.419935,"top":0.651111,"width":0.156862,"height":0.01576999999999995}},{"text":"negative","bbox":{"left":0.586601,"top":0.651111,"width":0.07843100000000003,"height":0.01576999999999995}},{"text":"numbers","bbox":{"left":0.674837,"top":0.651111,"width":0.068627,"height":0.01576999999999995}},{"text":"- assign negative weight to the most","bbox":{"left":0.184641,"top":0.678889,"width":0.352941,"height":0.01576999999999995}},{"text":"significant bit (MSB)","bbox":{"left":0.547386,"top":0.678889,"width":0.2058819999999999,"height":0.01576999999999995}},{"text":"- results","bbox":{"left":0.184641,"top":0.706667,"width":0.08823399999999998,"height":0.01576999999999995}},{"text":"in asymmetry","bbox":{"left":0.28268,"top":0.706667,"width":0.117647,"height":0.01576999999999995}},{"text":"- there is","bbox":{"left":0.410131,"top":0.706667,"width":0.09803899999999999,"height":0.01576999999999995}},{"text":"one more negative number","bbox":{"left":0.517974,"top":0.706667,"width":0.2352939999999999,"height":0.01576999999999995}},{"text":"- some important","bbox":{"left":0.184641,"top":0.734444,"width":0.156862,"height":0.01576999999999995}},{"text":"numbers","bbox":{"left":0.351307,"top":0.734444,"width":0.068627,"height":0.01576999999999995}},{"text":"at the boundaries:","bbox":{"left":0.429739,"top":0.734444,"width":0.17647000000000002,"height":0.01576999999999995}},{"text":"0x00....00 \n 0x7F....FF \n 0x80....00 \n 0xFF....FF","bbox":{"left":0.243464,"top":0.762222,"width":0.09803899999999999,"height":0.05743699999999996}},{"text":"- to","bbox":{"left":0.184641,"top":0.831667,"width":0.039215,"height":0.01576999999999995}},{"text":"negate n-bit integer:","bbox":{"left":0.23366,"top":0.831667,"width":0.20588199999999998,"height":0.01576999999999995}},{"text":"binary-subtract the number from 2^n, or \n flip the bits and binary-add 1.","bbox":{"left":0.243464,"top":0.859444,"width":0.38235299999999994,"height":0.02965899999999999}},{"text":"equivalently,","bbox":{"left":0.635621,"top":0.859444,"width":0.12745099999999998,"height":0.01576999999999995}}],"images_bbox":[],"images_bbox_not_text_overlap":[]}