RealTime Interview Questions

JRD Systems, Michigan 

1) Why ArrayList faster while searching than LinkedList
2) Time complexity of HashMap
3) Time complexity of ArrayList
4) Keeping an employee object as a key in hashmap without overriding equals and hashmap. Can we get an error?
5) What is View in Struts?
6) Explain end to end application for employee data from database using Angular and Spring?
7) Explain Jenkins configuration for a job?
 

Infosys AWS- JAVA interview – 1st round

Basic/Minimum permissions required to connect S3 from Ec2 instance?
What is cloud formation?
Can we use the same subnet in different regions?
How do you access the internet in private VPC network?
Explain ElasticBean Stack?
How Ops configuration is different from doing through ElasticBeanStack?
Explain about VPC?
How to get aws instance metadata?
The advantage of versioning in S3?

The difference between String, StringBuilder and StringBuffer?
Overloading vs Overriding?
Can we override the main method?
Explain Singleton class?
When to use ArrayList vs LinkedList?
What is marker interface?
Spring dependency Injection?
Explain Spring AOP?
ORM technologies?
Explain about Hibernate usage and advantages?

 

 

humana kentucky

– Difference between inteface and abstract class ?
– What is polymorphism, explain the different between runtime polymorphism vs compiletime polymorphism ?
– Difference between throw vs throws keywords?
– Explain Enum ?
– What is dry principle in java?
– Difference between hashmap vs concurrent hashmap?
– What is dependency injection ?
– ConcurrentHashMap vs SynchronizedHashMap
– Which two methods needs to override to implement your own hashmap ?
– Difference between Set vs List ?
– Default scope of bean in Spring Framework ?
– Explain dependency injection ?
– Mongo DB :
    – How do you represent table in Mongo DB?
    – How do you represent row in Mongo DB?
    – How do you display data in very nice format after extracting from Mongo DB ?
    – Explain query to select data from Mongo DB?
– Database : 
    – How do you fine tune your DB query ?
    – How do you sync data between two databases ?
    – Display all rows from table A by eliminating similar rows in table B
– Questions on synchronization ? 
– Explain Genrics?    
– What did you do with Redis ?
– How does in memory cache works?

CITI Group 1st Round Technical Evaluation

1) What are Generics in JAVA ?
Answer: Generics add stability to your code by making more of your bugs detectable at compile time.
 – Stronger type checks at compile time.
 – Elimination of 
casts.
 – The most commonly used type parameter names are:
E – Element (used extensively by the Java Collections Framework)
K – Key
N – Number
T – Type
V – Value

S,U,V etc. – 2nd, 3rd, 4th types
Type inference is a Java compiler's ability to look at each method invocation and corresponding declaration to determine the type argument (or arguments) that make the invocation applicable. 

2) select query Optimization?
 – Create the indexes
 – OnlyRetrive the data that you needed
 – Avoid Functions on the
Left Hand-Side of the Operator (Instead of WHERE DATEDIFF(MONTH, appointment_date, '2015-04-28') < 0; Do WHERE appointment_date > '2015-04-30')
 – Consider Getting Rid of Correlated Subqueries (Instead of subqueries create joins)
 – Avoid Wildcard Characters at the Beginning of a LIKE Pattern

3) Many to Many implementation in sql?

4) Spring bean scopes?
   singleton, prototype, request, session, global session
   http://docs.spring.io/spring/docs/3.0.0.M3/reference/html/ch04s04.html
   Please be aware that Spring's concept of a singleton bean is quite different from the Singleton pattern as defined in the seminal Gang of Four (GoF) patterns book. The GoF Singleton hard codes the scope of an object such that one and only one instance of a particular class will ever be created per ClassLoader. The scope of the Spring singleton is best described as per container and per bean. This means that if you define one bean for a particular class in a single Spring container, then the Spring container will create one and only one instance of the class defined by that bean definition. The singleton scope is the default scope in Spring. To define a bean as a singleton in XML, you would write configuration like so:

5) What is dependency injection?
 – Dependency injection is basically providing the objects that an object needs (its dependencies) instead of having it construct them itself

6) Explain ThreadPoolExecutor ?
   Executor:
 – The Concurrency API introduces the concept of an ExecutorService as a higher level replacement for working with threads directly. Executors are capable of running asynchronous tasks and typically manage a pool of threads, so we don't have to create new threads manually. All threads of the internal pool will be reused under the hood for revenant tasks, so we can run as many concurrent tasks as we want throughout the life-cycle of our application with a single executor service.
http://winterbe.com/posts/2015/04/07/java8-concurrency-tutorial-thread-executor-examples/  
  
7) How to make a class 
immutable?
  – Make all fields final and private & No public setter methods.
  – Make class final
  – Make a private constructor and add a public factory method.

8) Set vs List?
  – List allows duplicates &its an ordered collection
  – Set doesn't allow duplicates & random order

http://kaizen-koka.com/2016/01/19/collections/
   

9) How does SET eliminates duplicates?
  – If hashCodes equal and objects equal, then the insertion is resolved as duplicated element and the add method returns false. Except for TreeSet. In TreeSet, the TreeSet uses either the Comparable or Comparator interfaces. 

10) Why do we need ThreadExecutor when we have a Runnable, Thread?

11) Difference between comparator vs comparable?
   – http://kaizen-koka.com/2016/01/19/collections/ 

12) How do you choose between ArrayList vs LinkedList?
   – Based on operations. Read, Insert, and Delete. Read is faster with ArrayList andLinkedlIst faster in insertion and deletion.

13) Explain is-a relationship vs has-a relationship?
   – Composition is dynamic binding (run-time binding) while Inheritance is static binding (compile time binding)
   – One of the advantages of an Object-Oriented programming language is code reuse. There are two ways we can do code reuse either by the 
vimplementation of inheritance (IS-A relationship), or object composition (HAS-A relationship).
   – the concept of IS-A is a totally based on Inheritance. Inheritance is unidirectional.
   – Composition(HAS-A) simply mean the use of instance variables that are references to other objects.
    
14) Database
Normalization ?
  – In order to remove redundancy in database, normalization is applied. Normalization is the process of eliminating redundant data from database tables. There are 5 levels of normalization
  – 1 NF (1st normal form deals with data redundancy within each table record. check each row has redundancy) ,
  – 2 NF (2nd normal form deals with data redundancy that occurs vertically across the different rows in a table. check each column), & 
  – 3 NF the 3rd normal form requires that each column in a database table must be:
        1. dependent on the table's primary key
        2. independent on all other non-key columns in the table.

 

 

INFOSYS (Seattle) Interview Questions (12/09/2016) 

 1)  Thread Local ? What is the use of it ?
2)  Java Singleton & Synchronization ?
3)  The difference between the Runnable and Callable interfaces in Java ?
4)  What is the difference between microservices vs monolithic application ?
5)  What is the difference between microservice vs 
soa ?
6)  Explain Factory Pattern ?
7)  UserDefined Exceptions ?
8)  Write a program to find 'first 
nonrepeatable character in String' ?
9)  Can we write a public constructor in abstract class ? If so, what will happen ?
10) What is normalization in 
data base ?
11)
Difference between primary key vs unique key ?
12) Spring cloud discovery service (eureka) works ?
13) How do you achieve scalability with microservices(
spring boot) ?
14) Approach to resolve the high priority production issue ?
 

NIKE Interview Questions ?

 – Tell us about yourself ?
 – Explain your current project?
 – Can you explain aboutHystrics?
 – How does Circuit Breaker with
 –
 – Explain How to implement AWS Lamba?
 – Restful service exceptions?
 – Restful Services vs Soap ?
?Hystrics
Difference between Hibernate and iBatis ORM Technologies?
 – When to use Ibatis ?
 – Angular Js Modules technology?
 – Explain Rest Methodsavaliables
?
 –
Difference between POST vs PUT in REST?
 – AWS Route53
 – AWS Elastic LoadBalancer 

2 thoughts on “RealTime Interview Questions

Leave a Reply

Your email address will not be published. Required fields are marked *