Procedure of Creating Objects

Consider the following Procedure of Creating Objects:
  • Objects are basic run time entities
  • The declaration of class does not define any objects but it specifies what they will contain.
  • An object can be created using the following statement
item x;
  • Any number of the objects of same class can be created
item x, y, z;
  • Three objects x , y and z created with separate space in the memory
  • There is another syntax of creating objects

Class item
{
…..
…..
} x,y,z;




Post a Comment

Previous Post Next Post