Epsilon
A.O. Smith Interview Questions and Answers
Q1. What is the differences between Java and Python?
Java is statically typed, object-oriented language with a focus on performance and scalability. Python is dynamically typed, high-level language known for its simplicity and readability.
Java is statically typed, meaning variable types are explicitly declared at compile time. Python is dynamically typed, allowing for more flexibility but potentially leading to runtime errors.
Java is more verbose and requires more boilerplate code compared to Python, which emphasizes readabilit...read more
Q2. Write a program to check if a given string can become palindrome if letters are re-arranged
Program to check if a string can be rearranged to form a palindrome
Create a frequency map of characters in the string
Count the number of characters with odd frequencies
If there is at most one character with odd frequency, the string can be rearranged to form a palindrome
Q3. Write SQL query to find 2nd largest Number from DB?
Use a subquery to find the 2nd largest number in a database table.
Use a subquery to select all distinct numbers from the table
Order the numbers in descending order
Use LIMIT 1,1 to select the second row which will be the 2nd largest number
Q4. What is diamond problem in Java?
Diamond problem in Java occurs when a class inherits from two classes that have a common ancestor, resulting in ambiguity.
Occurs in multiple inheritance when a class inherits from two classes that have a common ancestor
Results in ambiguity as the compiler cannot determine which method to call
Can be resolved using interfaces or by explicitly overriding methods
Q5. Different Data types in Python ?
Python supports various data types including integers, floats, strings, lists, tuples, dictionaries, and more.
Integers: whole numbers without decimal points (e.g. 5, -3)
Floats: numbers with decimal points (e.g. 3.14, -0.5)
Strings: sequences of characters enclosed in quotes (e.g. 'hello', '123')
Lists: ordered collections of items (e.g. [1, 'apple', True])
Tuples: ordered, immutable collections of items (e.g. (1, 'banana', False))
Dictionaries: unordered collections of key-value ...read more
Q6. What is Normalization ?
Normalization is the process of organizing data in a database to reduce redundancy and improve data integrity.
Normalization is used to eliminate data redundancy by dividing the database into multiple tables and defining relationships between them.
It helps in reducing data anomalies such as insertion, update, and deletion anomalies.
Normalization is achieved through a series of stages called normal forms (1NF, 2NF, 3NF, BCNF, etc.).
For example, in a database of students and cou...read more
Q7. Latest version of Java
Java 17 is the latest version as of September 2021.
Java 17 was released on September 14, 2021.
It includes new features like sealed classes, pattern matching for switch statements, and more.
Oracle provides long-term support for Java 17 until 2029.
More about working at Epsilon
Reviews
Interviews
Salaries
Users/Month