On 12/28/06, Santosh Vernekar <[EMAIL PROTECTED]> wrote:


    You might want to try understanding how to access different fields of
a structure.
Every structure can be visualized like a block of memory and accessing
fields is like
accessing  the block at different offsets depending on the sizes of the
fields.
    Hence ..
typedef  struct {                    *char  **ch;
                   *int*  id;
                   *float*  salary;
  } Base;

Base orgin;


origin + 0 (Start Address)  point to the first element (char *ch)
origin + (sizeof char *)   points to the second element in the block (int
id)


Not necessarily, and unless you specify certain options in the compiler, not
ususally.

--
PJH

#713059 +(1255)- [X]

<SaintAlvus> Does the name Doctor Pavlov ring a bell?

Reply via email to