User Tools

Site Tools


user:mgardne8:portfolio:notescrap

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revisionPrevious revision
Next revision
Previous revision
user:mgardne8:portfolio:notescrap [2014/09/02 10:03] mgardne8user:mgardne8:portfolio:notescrap [2014/09/02 10:34] (current) mgardne8
Line 1: Line 1:
 __Pointers__ __Pointers__
 +  int = 4 bytes
 +  short = 2 bytes
  
-Grid - 1byte 8bits+  Int    a  5; (43;44;45;46) 
 +  Int    b =  6; (47;50;51;52) 
 +  Short  j =  2; (53;54) 
 +  Short  k =  1; (55;56) 
 +  Int   *c = &a; (57;60;61;62;63;64;65;66) 
 +                 [Contains Address for Int a; (43;44;45;46) 
 +                 [* = Dereferencing operator] 
 +  Short  q = 77; (67;70)
  
-2^8  - 256 +   |0|1|2|3|4|5|6|7| 
-         Int a; +  ------------------ 
-   |0|1|2|3|4|5|6|7|8+  0| | | | | | | | | 
-  -------------------- +  ------------------ 
-  0| | | | | | | | | +  1| | | | | | | | | 
-  -------------------- +  ------------------ 
-  1| | | | | | | | | +  2| | | | | | | | | 
-  -------------------- +  ------------------ 
-  2| | | | | | | | | +  3| | | | | | | | | 
-  -------------------- +  ------------------ 
-  3| | | | | | | | | +  4| | | |a|a|a|a|b
-  -------------------- +  ------------------ 
-  4| | | | | | | | +  5|b|b|b|j|j|k|k|c
-  -------------------- +  ------------------ 
-  5| | | | | | | | +  6|c|c|c|c|c|c|c|q
-  -------------------- +  ------------------ 
-  6| | | | | | | | +  7|q| | | | | | | | 
-  -------------------- +  ------------------
-  7| | | | | | | | | +
-  -------------------- +
-  8| | | | | | | | | | +
-  --------------------+
  
-__________________________________________ +---------------------------- 
-bc -l+  Grid - 1byte = 8bits 
 +---------------------------- 
 +  bc -l 
 +  2^8  = 256 
 +  2^16 = 65536 
 +  2^32 = 4294967296 
 +  2^64 = 18446744073709551616 
 +--------------------------- 
 +  X64 0x0000000000000000 
 +---------------------------
  
-2^8  256+  int g[4]; 
 +  int *g=(int *)malloc(sizeof(int)*4); 
 +   
 +  g[0]     7; 
 +  g[1]     3; 
 +  *(g+2) =  13; 
 +  g[2]    13; 
 +   
 +--------------------
  
-2^16 = 65536 
  
-2^32 = 4294967296 
  
-2^64 = 18446744073709551616 
-__________________________________________ 
- 
-X64 0x0000000000000000 
- 
-int = 4 bytes 
-short = 2 bytes 
  
  
user/mgardne8/portfolio/notescrap.1409666586.txt.gz · Last modified: 2014/09/02 10:03 by mgardne8