Languages-Java [3i Infotech Placement]: Sample Questions 14 - 15 of 141

Glide to success with Doorsteptutor material for competitive exams : get questions, notes, tests, video lectures and more- for all subjects of your exam.

Question 14

Edit

Write in Short

Short Answer▾

What is a wrapper classes?

Explanation

Define Wapper Classes Hierarchy
  • Wrapper class object wraps or contains primitive data types.
  • Object to a wrapper class contains a field that stores a primitive data type.

Question 15

Edit

Describe in Detail

Essay▾

What are the advantages of java over c ++ ?

Explanation

  • Easy to learn:
    • Java is easier to learn.
    • Take less time to learn the core concepts and syntax.
  • No pointers:
    • Using pointers without proper knowledge is a tragedy.
  • platform independent:
    • Compiles java code can run on all platforms that support java without the need for recompilation.
  • Garbage collection:
    • JVM garbage collector does automatic memory management.
    • Prevents memory leak in java application.
  • Just in time compiler:
    • Java uses JIT compiler to execute java byte code- faster.
    • JIT compiler is independent of JVM.
  • Concurrent:
    • Multi-threaded applications are easy to create in java- inherently threaded.
  • Reflective:
    • Java provides the ability to examine, introspect, and modify its own structure and behaviour at runtime.
  • Exception handling:
    • C ++ supports exception handling but Java has extra features like finally block and throws.
  • Easy to display:
    • Creating packages in java provides ease of deployment.
    • Java has its own archive formats like . jar for application deployment.
  • Web application:
    • Java is one of the important languages for web application.
    • J2EE can create robust enterprise level web applications.

Developed by: