Add office photos
Engaged Employer

Ernst & Young

3.5
based on 9.9k Reviews
Filter interviews by

20+ Interview Questions and Answers

Updated 25 Apr 2024
Popular Designations
Q1. Java Question

Which among String or String Buffer should be preferred when there are lot of updates required to be done in the
data?

Add your answer
Q2. Spring Boot Question

What is the @Controller annotation used for? How can you create a controller without an annotation?

Add your answer
Q3. Java Question

What are the advantages of Packages in Java?

Add your answer
Q4. Java Question

How would you differentiate between a String, StringBuffer, and a StringBuilder?

Add your answer
Discover null interview dos and don'ts from real experiences
Q5. Spring Boot Question

What Are the Basic Annotations that Spring Boot Offers?

Add your answer
Q6. Java Question

Why Java is platform independent and JVM platform dependent?

Add your answer
Are these interview questions helpful?
Q7. Java Question

What are some standard Java pre-defined functional interfaces?

Add your answer
Q8. Hibernate Question

Can you tell the difference between setMaxResults() and setFetchSize() of Query?

Add your answer
Share interview questions and help millions of jobseekers 🌟
Q9. Spring Boot Question

What is dependency Injection?

Add your answer
Q10. Java Question

What are the features of a lambda expression?

Add your answer
Q11. Spring Boot Question

What does the @SpringBootApplication annotation do internally?

Add your answer
Q12. Hibernate Question

What are the concurrency strategies available in hibernate?

Add your answer
Q13. Microservices Question

What issues are generally solved by spring clouds?

Add your answer
Q14. OOPS Question

What is meant by Interface?

Add your answer
Q15. Hibernate Question

Can you tell something about the N+1 SELECT problem in Hibernate?

Add your answer
Q16. Java Question

Explain the use of final keyword in variable, method and class

Add your answer
Q17. OOPS Question

Difference between Abstract class and Interface.

Add your answer
Q18. Spring Boot Question

Explain @RestController annotation in Sprint boot?

Add your answer
Q19. Microservices Question

Explain the working of Microservice Architecture.

Add your answer

Q20. How can we create our own immutable class

Ans.

An immutable class in Java can be created by declaring the class as final, making all fields private and final, and not providing any setter methods.

  • Declare the class as final to prevent inheritance

  • Make all fields private and final to prevent modification

  • Do not provide any setter methods to prevent changing the state

  • Initialize all fields in the constructor

  • Avoid returning mutable objects or references to internal mutable objects

View 1 answer

Q21. Difference between checked and unchecked exceptions.

Ans.

Checked exceptions are checked at compile-time while unchecked exceptions are not.

  • Checked exceptions are checked at compile-time and must be handled or declared in the method signature.

  • Unchecked exceptions are not checked at compile-time and do not need to be handled or declared.

  • Checked exceptions are usually used for recoverable errors while unchecked exceptions are used for unrecoverable errors.

  • Examples of checked exceptions include IOException and SQLException while exampl...read more

Add your answer

Q22. How you would connect springboot project with data base.

Ans.

Use Spring Data JPA to connect Spring Boot project with database.

  • Add database configuration in application.properties or application.yml file

  • Create entity classes annotated with @Entity and @Table

  • Create repository interfaces extending JpaRepository

  • Use @Autowired annotation to inject repository in services or controllers

Add your answer

Q23. Difference between String and String Builder

Ans.

String is immutable, StringBuilder is mutable.

  • String is a sequence of characters stored in the heap memory.

  • String Builder is a mutable sequence of characters stored in the heap memory.

  • String objects are immutable, meaning their values cannot be changed once created.

  • String Builder objects are mutable, meaning their values can be changed after creation.

  • String concatenation creates a new String object each time, which can be inefficient.

  • String Builder is more efficient for conca...read more

View 1 answer
Contribute & help others!
Write a review
Share interview
Contribute salary
Add office photos

Interview Process at null

based on 3 interviews in the last 1 year
1 Interview rounds
Technical Round
View more
Interview Tips & Stories
Ace your next interview with expert advice and inspiring stories

Top Java Developer Interview Questions from Similar Companies

3.7
 • 156 Interview Questions
3.0
 • 24 Interview Questions
3.9
 • 20 Interview Questions
4.0
 • 18 Interview Questions
3.6
 • 18 Interview Questions
3.9
 • 17 Interview Questions
View all
Share an Interview
Stay ahead in your career. Get AmbitionBox app
qr-code
Helping over 1 Crore job seekers every month in choosing their right fit company
70 Lakh+

Reviews

5 Lakh+

Interviews

4 Crore+

Salaries

1 Cr+

Users/Month

Contribute to help millions
Get AmbitionBox app

Made with ❤️ in India. Trademarks belong to their respective owners. All rights reserved © 2024 Info Edge (India) Ltd.

Follow us
  • Youtube
  • Instagram
  • LinkedIn
  • Facebook
  • Twitter