Add office photos
Engaged Employer

TechAffinity

3.8
based on 36 Reviews
Filter interviews by

ELV Projects Pvt Ltd Interview Questions and Answers

Updated 19 Dec 2024

Q1. What is a program to sort a list in descending order?

Ans.

Use a sorting algorithm like quicksort or mergesort to sort the list in descending order.

  • Implement a sorting algorithm like quicksort or mergesort to sort the list in descending order.

  • Modify the comparison function to sort the elements in descending order.

  • Ensure the sorting algorithm is efficient and handles edge cases like duplicate elements.

Add your answer

Q2. What is the difference between a set and a list?

Ans.

A set is an unordered collection of unique elements, while a list is an ordered collection of elements that may contain duplicates.

  • Sets do not allow duplicate elements, while lists can have duplicate elements.

  • Sets are unordered, meaning the elements do not have a specific order, while lists maintain the order of elements.

  • Sets are typically used when the existence of an element is more important than the order or frequency, while lists are used when the order and duplicates ma...read more

Add your answer

Q3. Which one is better, Comparator or Comparable?

Ans.

Comparable is better for natural ordering, while Comparator is better for custom ordering.

  • Comparable is used to define the natural ordering of objects, while Comparator is used to define custom ordering.

  • Comparable is implemented by the class whose objects need to be compared, while Comparator is implemented by a separate class.

  • Comparable uses the compareTo() method to compare objects, while Comparator uses the compare() method.

  • Example: String class implements Comparable inter...read more

Add your answer

Q4. What is Spring AOP (Aspect-Oriented Programming)?

Ans.

Spring AOP is a programming paradigm that allows separating cross-cutting concerns from the main application logic.

  • Spring AOP enables modularization of concerns such as transaction management, logging, security, etc.

  • It allows defining aspects (cross-cutting concerns) and applying them to multiple classes.

  • AspectJ is a popular implementation of AOP in Spring framework.

  • Example: Using AOP to log method execution time across multiple classes.

Add your answer
Discover ELV Projects Pvt Ltd interview dos and don'ts from real experiences

Q5. What are the uses of HashSet and TreeSet in Java?

Ans.

HashSet is an unordered collection of unique elements, while TreeSet is a sorted set implemented using a tree structure.

  • HashSet does not maintain any order of elements, while TreeSet maintains elements in sorted order.

  • HashSet allows null values and is generally faster for adding, removing, and checking for existence of elements.

  • TreeSet does not allow null values and provides efficient operations for finding the smallest and largest elements.

  • HashSet is implemented using a hash...read more

Add your answer

Q6. What is the purpose of an interceptor?

Ans.

An interceptor is a software design pattern that allows for pre-processing and post-processing of requests and responses.

  • Interceptors can be used for logging, authentication, authorization, caching, error handling, and more

  • They can intercept HTTP requests and responses in web applications

  • Examples include Angular HTTP interceptors, Spring Interceptors in Java, and Axios interceptors in JavaScript

Add your answer

Q7. What is Spring Security?

Ans.

Spring Security is a powerful and customizable authentication and access control framework for Java applications.

  • Provides comprehensive security services for Java EE-based enterprise software applications

  • Supports authentication, authorization, and protection against common security vulnerabilities

  • Integrates with Spring Framework for seamless security configuration

  • Allows for easy customization and extension through configuration and programming

  • Example: Securing REST APIs with ...read more

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

Interview Process at ELV Projects Pvt Ltd

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

Top Interview Questions from Similar Companies

4.0
 • 683 Interview Questions
3.9
 • 520 Interview Questions
3.9
 • 467 Interview Questions
3.6
 • 197 Interview Questions
3.7
 • 192 Interview Questions
3.6
 • 178 Interview Questions
View all
Top TechAffinity Interview Questions And Answers
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