When is an object created and what is its lifetime?

Answers were Sorted based on User's Feedback



When is an object created and what is its lifetime?..

Answer / apurva jain

Object is created when constructor has to be invoked or
when have to access the class.Its Lifetime is throughout
the Execution of that Class.

Is This Answer Correct ?    30 Yes 8 No

When is an object created and what is its lifetime?..

Answer / nikhil

global scope,if created outside class n local scope if
created inside a class......

Is This Answer Correct ?    3 Yes 2 No

When is an object created and what is its lifetime?..

Answer / alok pandey

When the constructor called then object created thus while
the programme execute till life of object

Is This Answer Correct ?    2 Yes 2 No

When is an object created and what is its lifetime?..

Answer / yathirajulu

whenever developer is required, and the life-time is when we
assinging null or close the program(application).

Is This Answer Correct ?    2 Yes 14 No

Post New Answer

More OOPS Interview Questions

What is stream in oop?

0 Answers  


What type of loop is a for loop?

0 Answers  


what is the difference between virtual function and destoctor?

1 Answers  


what is multithreading in c++ , what is difference between multithreading and singlethreading.

4 Answers  


what is opps?why it is use in programming language?

2 Answers   Wipro,






What is byval and byref? What are differences between them?

0 Answers   HCL, Wipro,


what is single inheritance?

18 Answers   IBM,


What is Difeerence between List obj=new ArrayList(); and ArrayList obj=new ArrayList()?

0 Answers   NIIT, SRA,


what type of question are asked in thoughtworks pair programming round ?

0 Answers   Thought Works,


What is object and example?

0 Answers  


Program to check whether a word starts with a capital letter or not.

1 Answers   Infosys,


What exactly is polymorphism?

0 Answers  


Categories