Core%20java - Interview Questions and Answers for 'Emory' | Search Interview Question - javasearch.buggybread.com
Javasearch.buggybread.com

Search Interview Questions


 More than 3000 questions in repository.
 There are more than 900 unanswered questions.
Click here and help us by providing the answer.
 Have a video suggestion.
Click Correct / Improve and please let us know.
Label / Company      Label / Company / Text

   



Core%20java - Interview Questions and Answers for 'Emory' - 0 question(s) found - Order By Newest

 Q1. Function variables are kept in ..Core Java
a. Stack
b. Heap
c. Both Stack and Heap
d. None of them

Ans.a. Stack

 Q2. Which memory segment holds String Pool ?Core Java
a. Stack
b. Heap
c. Code Segment
d. Class Segment

Ans.b. Heap

 Q3. In this code

public class BuggyBread1{
   private static String staticVariable = "static Variable";
   
   private String instanceVariable = "instance Variable";
   
   public static void main (String args[]) {
String localVariable = "local Variable";
}
}

Where will the value 'static Variable' be stored ?
Core Java
a. Stack Memory Segment
b. Heap Memory Segment
c. Runtime Constant Pool within Heap Segment
d. Code Segment

Ans.c. Runtime Constant Pool within Heap Segment

 Q4. In this code

public class BuggyBread1{
   private static String staticVariable = "static Variable";
   
   private String instanceVariable = "instance Variable";
   
   public static void main (String args[]) {
String localVariable = "local Variable";
}
}

Where will the value 'static Variable' be stored ?
Core Java
a. Stack Memory Segment
b. Heap Memory Segment
c. Runtime Constant Pool within Heap Segment
d. Code Segment

Ans.c. Runtime Constant Pool within Heap Segment

 Q5. In this code

public class BuggyBread1{
   private static String staticVariable = "static Variable";
   
   private String instanceVariable = "instance Variable";
   
   public static void main (String args[]) {
String localVariable = new String("local Variable");
}
}

Where will the value 'local Variable' be stored ?
Core Java
a. Stack Memory Segment
b. Heap Memory Segment
c. Runtime Constant Pool within Heap Segment
d. Code Segment

Ans.a. Stack Memory Segment

 Q6. In this code

public class BuggyBread1{
   private static String staticVariable = new String("static Variable");
   
   private String instanceVariable = "instance Variable";
   
   public static void main (String args[]) {
String localVariable = "local Variable";
}
}

Where will the value 'static Variable' be stored ?
Core Java
a. Stack Memory Segment
b. Heap Memory Segment
c. Runtime Constant Pool within Heap Segment
d. Code Segment

Ans.b. Heap Memory Segment

 Q7. Which of following memory segment is cleaned by Garbage Collection Mechanism ?Core Java
a. Stack
b. Heap
c. Code
d. Cache

Ans.b. Heap


Help us and Others Improve. Please let us know the questions asked in any of your previous interview.

Any input from you will be highly appreciated and It will unlock the application for 10 more requests.

Company Name:
Questions Asked: