ALLInterview.com :: Home Page            
 Advertise your Business Here     
Browse  |   Placement Papers  |   Company  |   Code Snippets  |   Certifications  |   Visa Questions
Post Question  |   Post Answer  |   My Panel  |   Search  |   Articles  |   Topics  |   ERRORS new
   Refer this Site  Refer This Site to Your Friends  Site Map  Bookmark this Site  Set it as your HomePage  Contact Us     Login  |  Sign Up                      
Google
   
 
Categories >> Software >> Java Related >> Java J2EE >> Core Java
 
 


 

 
 Core Java interview questions  Core Java Interview Questions (1721)
 Advanced Java interview questions  Advanced Java Interview Questions (331)
 Swing interview questions  Swing Interview Questions (44)
 EJB interview questions  EJB Interview Questions (134)
 Servlets interview questions  Servlets Interview Questions (255)
 Struts interview questions  Struts Interview Questions (196)
 JDBC interview questions  JDBC Interview Questions (187)
 JMS interview questions  JMS Interview Questions (9)
 SunOne interview questions  SunOne Interview Questions (3)
 J2EE interview questions  J2EE Interview Questions (71)
 Weblogic interview questions  Weblogic Interview Questions (146)
 Websphere interview questions  Websphere Interview Questions (14)
 Java Networking interview questions  Java Networking Interview Questions (20)
 Java J2EE AllOther interview questions  Java J2EE AllOther Interview Questions (87)
Question
what is the use of reference variable
 Question Submitted By :: Azitkumarreddy
I also faced this Question!!     Rank Answer Posted By  
 
  Re: what is the use of reference variable
Answer
# 1
A reference variable is used to refer a particular object
location which resides on a garbage collectable heap
 
Is This Answer Correct ?    15 Yes 6 No
Ravikiran(aptech Mumbai)
 
  Re: what is the use of reference variable
Answer
# 2
A refference variable is a variable which will act as a
adress to a object.... in stack area and the object which
is created will get allocated memory in heap area.
 
Is This Answer Correct ?    1 Yes 3 No
Venkatachalapathy
 
 
 
  Re: what is the use of reference variable
Answer
# 3
reference will act as variable to point an object. Instead
of giving direct memory location(using pointers)to the
programmer java internally converted them into references,
so that java can avoid memory leaks and increase performance
in accessing object.
 
Is This Answer Correct ?    4 Yes 0 No
Venkatesh
 
  Re: what is the use of reference variable
Answer
# 4
c++ supports one more type of variable called reference
variable.In addition to pointer variable and value variable
of creference variable behaves similar to both vaule
variable and pointer variable.reference variable has all
acces that variable has.
 
Is This Answer Correct ?    3 Yes 2 No
Aatish Maskariya
 
  Re: what is the use of reference variable
Answer
# 5
The reference variable is useful in OOP because it permits the manipulation of objects by reference, and eliminates the copying of object parameters back and forth. It is also important to note that reference can be created not only for built_in data types but also for user defined data types such as structures and classes 
Is This Answer Correct ?    0 Yes 0 No
Seema Yadav
 
  Re: what is the use of reference variable
Answer
# 6
As Pointers are not safe and secure which allows us to increament or decreament the memory locations such that we can reach the O.S related files.
So to avoid such insecurities we go with Reference Varaibles where we can't increament or decrement memory location of an object.Even if we try to print the address of the object it prints some hash code
 
Is This Answer Correct ?    2 Yes 0 No
Siri
 

 
 
 
Other Core Java Interview Questions
 
  Question Asked @ Answers
 
What is AppletStub?   1
Hai friends I am MCA 2006 passout. Spend time in 1 yr for teacing and 5 months in small s/w firm. worked in 4 or 5 months in few places. Presently I am writing bank exams. I want to get back to IT sector. Are there any possibilities. any growth prospects?. I am having some knowledge in core and advanced java. I am so desperate. Any suggestions thanks in advance. u can write to my mail mahidestiny@gmail.com   4
printstream class method println() is calling using System class and its static object out .how it is explain any one in detail with example ? TCS 1
What is Exception handling in Java How do you handle run time errors please explain with an example TCS 2
I have a Arraylist object, it has duplecate values also. Now question is i want delete duplecate data in that objet with out using Set? Aricent 8
In what circumstances, compiler will supply a default constructor for a class?   4
Which method will get invoked first in a stand alone application?   1
static inner classes means..?   1
What is deadlock and how to avoid this?   2
what is jdk1.5 features? Virtusa 6
Explain the difference between getAppletInfo and getParameterInfo?   1
In what types of operations an ArithmeticException will be thrown?   3
 
For more Core Java Interview Questions Click Here 
 
 
 
 
 


   
Copyright Policy  |  Terms of Service  |  Articles  |  Site Map  |  RSS Site Map  |  Contact Us
   
Copyright 2013  ALLInterview.com.  All Rights Reserved.

ALLInterview.com   ::  KalAajKal.com