1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

Why all pointers take only 2 or 4 bytes of space? Then what is the use of datatype ke

Discussion in 'C' started by Tech_Khalsa, Jul 22, 2007.

  1. Tech_Khalsa

    Tech_Khalsa New Member

    Joined:
    Jul 22, 2007
    Messages:
    3
    Likes Received:
    0
    Trophy Points:
    0
    Why all pointers take only 2 or 4 bytes of space? Then what is the use of datatype keywords.
     
  2. shabbir

    shabbir Administrator Staff Member

    Joined:
    Jul 12, 2004
    Messages:
    15,293
    Likes Received:
    365
    Trophy Points:
    83
    Pointers are address to some locations and so you need constant amount of space to define each address uniquely.

    Now the keywords are kept for what type of data is pointed to by the pointer and also for determining the size of the incrementing counter when moving through the pointers.
     

Share This Page