Java Online Test

Java Online Test

Evaluate aptitude, technical and coding skills with Adaface skills assessment platform powered with an intelligent chatbot

Evaluate aptitude, technical and coding skills with Adaface skills assessment platform powered with an intelligent chatbot
  • amazon
  • paypal
  • UCLA
  • lovebonito
  • singapore-government
  • nielson
  • adidas

Sample Questions

Sample Questions

These are just a small sample from our library of 10,000+ questions. The actual questions on this test will be non-googleable.

🧐 Question 🔧 Skill 💪 Difficulty ⌛ Time
Custom Exception - What does the following cod...
Exceptions
Java Easy 2 min
Holding References - What does the following Jav...
Java Medium 2 min
Abstract Interface - Given following interface:
OOPs Interfaces
Java Medium 2 min
Garbage Collection - After which line is "bs" ob...
Garbage Collection
Java Medium 2 min
Static Init Blocks - What does the following cod...
OOPs
Java Medium 2 min
Java
Custom Exception
Custom Exception
Exceptions
Duration ⌛
Difficulty 💪
: 2 mins
: Easy

What does the following code output?

View Question
Java
Holding References
Holding References
Duration ⌛
Difficulty 💪
: 2 mins
: Medium

What does the following Java code output?

View Question
Java
Abstract Interface
Abstract Interface
OOPs Interfaces
Duration ⌛
Difficulty 💪
: 2 mins
: Medium

Given following interface:

View Question
Java
Garbage Collection
Garbage Collection
Garbage Collection
Duration ⌛
Difficulty 💪
: 2 mins
: Medium

After which line is "bs" object, created on Line 4, eligible for ga...

View Question
Java
Static Init Blocks
Static Init Blocks
OOPs
Duration ⌛
Difficulty 💪
: 2 mins
: Medium

What does the following code output?

View Question

"Met Adaface, waren we in staat om onze eerste screening proces te optimaliseren door ruim 75%, het vrijmaken van kostbare tijd voor zowel de managers en ons talent acquisitie team!"


- Brandon Lee, hoofd van de Mensen, Liefde, Bonito

Start using conversational Java Online Test for the most accurate and candidate friendly screening today
Start using conversational Java Online Test for the most accurate and candidate friendly screening today
💼
Customized assessments for every experience level
Customized assessments for every experience level

Customized by subject matter experts to cater to job roles for all experience levels (fresh grads to 8-10 years) within your organization.

💯
Higher test taking rate compared to traditional tests
Higher test taking rate compared to traditional tests

Adaface assessments have an average test taking rate of 86% as compared to an industry standard of 50%.

🎯
Accurate evaluation using on-the-job, non-tricky questions
Accurate evaluation using on-the-job, non-tricky questions

Adaface assessments have relevant questions that test for on-the-job skills. We do not expect candidates to solve puzzles/ trick questions.

Sample Coding Conversation with Ada

Java JavaScript C++ C C# PHP Python React Angular Django Android iOS SQL MySQL HTML/CSS NodeJS Excel Data Interpretation Logical Reasoning Quantitative Aptitude Check out 700+ skills

Get a detailed scorecard with section wise breakdown and a pass/ fail recommendation

Get a detailed scorecard with section wise breakdown and a pass/ fail recommendation

Trusted by companies worldwide

Trusted by companies worldwide

"Het inhuren van managers van mening dat door de technische vragen die ze vroegen tijdens het panel interviews, waren ze in staat om te vertellen welke kandidaten betere scores had, en onderscheiden met degenen die niet zo goed scoorden. Ze zijn zeer tevreden met de kwaliteit van de kandidaten op de shortlist de Adaface screening."


- Human Resources Manager, Singapore Government

Everything you need to know about Java Online Test 👇

Everything you need to know about Java Online Test 👇

Adaface Java Online Test will be customized to accurately evaluate on-the-job skills required for your role. This assessment test is useful when you are hiring candidates for roles like - Core Java Developer, Core Java Programmer, Backend Developer.

Core Java Data Types Threads Servlets OOPs classes

Why You Should Use This Test

The Java Online test helps recruiters and hiring managers to identify qualified candidates from a pool of resumes, and helps in taking objective hiring decisions. It reduces the administrative overhead of interviewing too many candidates and saves expensive engineering time by filtering out unqualified candidates.

The Adaface tests screen candidates for the typical skills recruiters look for in a Java developer:

  • Core Java knowledge 
  • OOPs fundamentals
  • Understanding on interfacing, class overriding, polymorphism
  • Experience with Java Classes, Streams, Java 8 Lambda

The insights generated from this assessment can be used by recruiters and hiring managers to identify the best candidates for the role. Anti-cheating features enable you to be comfortable with conducting assessments online. The Java developer test is ideal for helping recruiters identify which candidates have the technical skills to do well on the job.

Questions in this Test



Number of sections 5
Number of questions 17
Duration 60 minutes
Language English


The Java Online test is designed to test for Java fundamentals and hands on coding skills.

  1. Java fundamentals: These questions are designed to evaluate a candidate's knowledge and expertise of technical concepts in Java-like OOPs, classes, interfaces, multithreading, design patterns, Java 8, exception handling, etc.
  2. Coding skills: These questions are designed to assess a candidate's programming ability and debugging skills in Java. In addition, these also test for problem-solving skills.


Core Java basics 5 MCQs
OOPs concepts 5 MCQs
Advanced Java topics 5 MCQs
Coding 1 coding question
Debugging 1 debugging question
TRY FOR FREE

(100% free to get started, no credit card required)

About This Test

The Java test will consist of ~15 MCQ, 1 coding challenge and 1 debugging challenge crafted by experts in the Java programming language and will cover a broad spectrum of topics within Java. Use this Java Online Quiz to streamline your hiring process.

The Java Online Test helps you screen candidates. Interview only candidates with proven hands-on technical expertise in Java development and programming.

The idea behind this online Java quiz is to help you assess on-the-job Java concepts, Core Java knowledge, coding and debugging skills with just one test.

Here is a list of topics (only for reference, actual topics and questions for your custom assessment will be chosen by our subject matter experts based on your job description/ ideal engineer persona).

OOPS concepts (Data Abstraction, Encapsulation, Inheritance, Polymorphism) Java classes and collections Collection framework Synchronisation
Core Java Java design patterns Multithreading JVM and Garbage Collection
Basic Java constructs like loops and data types String handling Exception handling Serialisation & De-serialisation
Concurrent collection JDBC (Java Database Connectivity) Servlet JSP
Web Services (SOAP & REST) Struts JSF Spring (MVC, Core, JDBC, ORM, AOP)
Hibernate ORM framework Java8 Java 7 Java 9
Java EE J2EE Java Swing Core Java
Bug fixing Stream Arithmetic Algorithmic Thinking

FAQs

What is meant by OOPS in Java?

Object Oriented programming is a programming style which is associated with the concepts like class, object, Inheritance, Encapsulation, Abstraction, Polymorphism. Most popular programming languages like Java, C++, C#, Ruby, etc. follow an object-oriented programming paradigm. In OOP, computer programs are designed in such a way where everything is an object that interact with one another. The main aim of OOP is to bind together the data and the functions that operate on them so that no other part of the code can access this data except that function.

What type of questions will the Java Online Test include?

The test is designed to enable recruiters and hiring managers to quickly identify which candidates should be invited to an interview. This test will assess candidates on their fundamentals and depth of Java programming languages with questions on OOPs basics, strings, classes, interfaces, multi-threading, design patterns, exception handling etc. The questions are designed to test for on-the-job Java skills as opposed to just theoretical concepts. The programming and debugging challenges test the problem solving and coding ability of your candidates.

What skills are required for a Java role?

Depending on the role and industry, a Java developer might require these skills:

  • Understanding of Object-Oriented Programming concepts.
  • Understanding of when to use design patterns such as Singleton, Factory, Fly-weight, Builder, Object Pool, Iterator, Strategy, Visitor, Composite. This skill is particularly important for senior Java developers who will have to work on the architecture of applications to design long-term solutions.
  • Understanding of the class loading process and how class loaders work.
  • Understanding the nuanced world of performance, whether that be memory overhead, computation complexity, or speed.
  • Knowledge of when memory is being allocated, from what context, and how it affects heap fragmentation.
  • Familiarity with the various garbage collection algorithms, and how to use the profilers.
  • Experience with JSP / Servlets, web Frameworks like Struts / Spring and Service Oriented Architecture / Web Services – SOAP / REST.
  • Ability to apply the most modern patterns and language features to existing systems.
  • Experience in using technologies in the Java ecosystem: Struts, Spring, Maven, Gradle, Ant, JUnit, Spock, and Hibernate, among many others.
  • Knowledge of the intricacies of SQL queries.
  • Ability to learn new technologies and willingness to step out of comfort zone to explore and learn new skills.
What is a custom assessment?

Every role is different and requires a custom assessment to identify top candidates efficiently. Adaface subject matter experts understand your job description/ role requirements and pick the most relevant questions from our library of 10000+ questions to create a technical assessment that helps you find the qualified candidates in your candidate pipeline quickly. All custom assessments are set up based on the job description, role requirements, must-have skills, experience level and salary range within a maximum of 48 hours and you will get an email notification once it goes live.

Check out a sample assessment here (no credit card required).

Can I combine multiple skills into one custom assessment?

Yes, absolutely. Custom assessments are set up based on your job description, and will include questions on all must-have skills you specify.

How is Adaface different from other assessment tools?

We believe that status quo tech assessment platforms are not a fair way for companies to evaluate engineers because they focus on trick questions/ puzzles/ niche algorithms. We started Adaface to help companies find great engineers by assessing on-the-job skills required for a role. Read more about why we started Adaface.

Here's what's different with Adaface:

  1. High quality non-googleable questions that test for on-the-job skills as opposed to theoretical knowledge.
  2. A friendly conversational assessment with a chatbot, instead of sending a "test" to a candidate. This translates to a higher completion rate. Adaface assessments (86% candidate completion rate), as opposed to traditional tests (40-50% candidate completion rate)
  3. Customized assessments for 700+ skills at different experience levels.
Do you have any anti-cheating features in place?

We have the following anti-cheating features in place:

  1. Web proctoring
  2. Webcam proctoring
  3. Plagairism detection
  4. Non-googleable questions
  5. Secure browser

How do I interpret test scores?

The primary thing to keep in mind is that an assessment is an elimination tool, not a selection tool. As in an assessment is optimizing to help you eliminate candidates who are not technically qualified for the role, it is not optimized to help you find the best candidate for the role. So the ideal way to use an assessment is to decide a threshold score (typically 60%, we help you benchmark) and invite all candidates who score above the threshold for the next rounds of interview.

What experience level can I use this test for?

Each Adaface assessment is customized to your job description/ ideal candidate persona (our subject matter experts will pick the right questions for your assessment from our library of 10000+ questions). This assessment can be customized for any experience level.

Does every candidate get the same questions?

Yes, it makes it much easier for you to compare candidates. Options for MCQ questions and the order of questions are randomized. We have anti-cheating features in place. In our enterprise plan, we also have the option to create multiple versions of the same assessment with questions of similar difficulty levels.

I'm a candidate. Can I try a practice test?

No. Unfortunately, we do not support practice tests at the moment.

What is the cost for using the Java Online Test?

You can check out our pricing plans here.

Can I get a free trial?

You can sign up for free and check out the platform here. The dashboard has a sample assessment for you to review the quality of questions and check out the candidate experience of a chat based assessment. Since our questions are premium, we are unable to share sample questions for a particular skill/ technology. You can also review our sample public questions here.

I just moved to a paid plan. How can I request a custom assessment?

Check out our quick guide on requesting a custom assessment here.

TRY FOR FREE

(100% free to get started, no credit card required)

Score Distribution

You should expect ~20% of the candidates to do well on Adaface assessments.

The score distribution for our assessments follow the normal curve. This is a good sign- standardized tests like SAT and GRE follow the normal distribution (bell curve).

Status quo assessments typically have the exact opposite of the bell curve (too many candidates getting close to 0, too many candidates getting close to 100 and too few candidates in the middle). This is typically because they focus on theoretical questions or trick questions, which are very binary in nature- either you know the trick/ theory or you don’t.

TRY FOR FREE

(100% free to get started, no credit card required)

About The Role

Java is a high-level programming language originally developed by Sun Microsystems and released in 1995. Java runs on a variety of platforms, such as Windows, Mac OS, and the various versions of UNIX.

Java is class-based, object-oriented, and designed to have as few implementation dependencies as possible. It is intended to let application developers write once, run anywhere, meaning that compiled Java code can run on all platforms that support Java without the need for recompilation.

Java is one of the most portable languages available at a developer’s disposal. It’s possible for a great Java developer to build a highly distributed web application, a sophisticated desktop application, or even a powerful mobile application running on a handheld device. With the power of Java Virtual Machine behind the platform, sometimes a talented developer is all it takes to build a robust, secure, and efficient application. This Java Online Test for hiring candidates focuses on testing for on-the-job skills.

Typical Java Developer responsibilities include:

  1. Designing and developing high-volume, low-latency applications for mission-critical systems and delivering high-availability and performance
  2. Analyzing user requirements to inform application design.
  3. Defining application objectives and functionality
  4. Integrating applications by designing database architecture and server scripting; studying and establishing connectivity with network systems, search engines, and information servers.
  5. Supporting users by developing documentation and assistance tools.

Interview Questions

Candidates who pass Adaface Java test can be taken for second round interviews directly. Here are some interview questions for intermediate and experienced candidates:

Why would it be more secure to store sensitive data (such as a password, social security number, etc.) in a character array rather than in a String?

In Java, Strings are immutable and are stored in the String pool. What this means is that, once a String is created, it stays in the pool in memory until being garbage collected. Therefore, even after you’re done processing the string value (e.g., the password), it remains available in memory for an indeterminate period of time thereafter (again, until being garbage collected) which you have no real control over. Therefore, anyone having access to a memory dump can potentially extract the sensitive data and exploit it.

In contrast, if you use a mutable object like a character array, for example, to store the value, you can set it to blank once you are done with it with confidence that it will no longer be retained in memory.

What will happen if we put a key object in a HashMap which is already there?

If you put the same key again then it will replace the old mapping because HashMap doesn't allow duplicate keys. The Same key will result in the same hashcode and will end up at the same position in the bucket.

Why do the methods: wait(), notify() and notifyAll() have to be called from synchronized method or block?

When a Thread calls wait() on any Object, it must have the monitor on the Object that it will leave and goes in wait state until any other thread call notify() on this Object. Similarly when a thread calls notify() on any Object, it leaves the monitor on the Object and other waiting threads can get the monitor on the Object. Since all these methods require Thread to have the Object monitor, that can be achieved only by synchronization, they need to be called from synchronized method or block.

Does Java support multiple inheritances?

Java does not support multiple inheritances through classes but through the interfaces, we can use multiple inheritances . The problem with multiple inheritance is that two classes may define different ways of doing the same thing, and the subclass can't choose which one to pick.

What are some of the improvements in Concurrency API in Java 8?

Some important concurrent API enhancements are:

  • ConcurrentHashMap compute(), forEach(), forEachEntry(), forEachKey(), forEachValue(), merge(), reduce() and search() methods.
  • CompletableFuture that may be explicitly completed (setting its value and status).
  • Executors newWorkStealingPool() method to create a work-stealing thread pool using all available processors as its target parallelism level.
What’s wrong using HashMap in the multi-threaded environment? When does the get() method go to an infinite loop?

Well, nothing is wrong, depending on how you use it. For example, if you initialize the HashMap just by one thread and then all threads are only reading from it, then it’s perfectly fine. One example of this is a Map which contains configuration properties. The real problem starts when at-least one of that thread is updating HashMap i.e. adding, changing or removing any key value pair. Since put() operation can cause re-sizing and which can further lead to infinite loop, that’s why either you should use Hashtable or ConcurrentHashMap, later is better.

Nested classes can be static or non-static (also called an inner class). How do you decide which to use? Does it matter?

The key difference between is that inner classes have full access to the fields and methods of the enclosing class. This can be convenient for event handlers, but comes at a cost: every instance of an inner class retains and requires a reference to its enclosing class.

With this cost in mind, there are many situations where we should prefer static nested classes. When instances of the nested class will outlive instances of the enclosing class, the nested class should be static to prevent memory leaks.

Inner classes are also harder to construct via reflection due to their “hidden” reference to the enclosing class, and this reference can get sucked in during reflection-based serialization, which is probably not intended. So we can see that the decision of whether to make a nested class static is important, and that one should aim to make nested classes static in cases where instances will “escape” the enclosing class or if reflection on those nested classes is involved.

What is the Factory pattern in Java? What is the advantage of using a static factory method to create an object?

The Factory pattern in Java is a creation Java design pattern and favorite on many Java interviews. Factory pattern used to create an object by providing static factory methods. There are many advantages of providing factory methods like caching immutable objects, easy to introduce new objects, etc.

Can we have an empty catch block?

Yes, we can use an empty catch block but it’s not a right way of programming. When we use an empty catch block and if it catches any exception then we will have no information about that exception and it will be a nightmare of the situation to debug it. There should be a log statement file for logging all the exception details.

What is the benefit of using a prototype design pattern over creating an instance using the new keyword?

Sometimes, object creation is heavyweight and requires a lot of resources, creating a new instance will impact the performance. In such cases, a prototype design pattern is used which refers to creating duplicate objects. In the prototype design pattern, if a similar object is already present then cloning is done keeping performance in mind.

Can an object be garbage collected whereas it’s still reachable?

A reachable object can’t garbage collected. Solely unreachable objects may garbage collected.

What is “dirty read” in JDBC?

When transactions taking place and there is some that a row is updated at the same time some query can read the updated value. This dirty read happens because that the updated value is not permanent yet, the transaction that has been updated could rollback to a previous value which will result in invalid data.

How do you avoid a deadlock in Java?

You can avoid deadlock by breaking the circular wait condition. In order to do that, you can make an arrangement in the code to impose the ordering on acquisition and release of locks.

If lock will be acquired in a consistent order and released in just opposite order, there would not be a situation where one thread is holding a lock which is acquired by other and vice-versa. See the detailed answer for the code example and more detailed explanation.

Full stack Java Tests

You can combine multiple skills into a single custom Adaface Java test. Here are some popular combinations for full stack roles.

Java & SQL Java & MySQL Java & PostgreSQL
Java & SQL & JavaScriptJava & MySQL & JavaScriptJava & PostgreSQL & JavaScript
Java & SQL & JavaScript & HTML5/CSS3Java & MySQL & JavaScript & HTML5/CSS3Java & PostgreSQL & JavaScript & HTML5/CSS3
Java & React Java & Android Java & Angular
Java & Spring Java & Spring & Hibernate Java & .NET
Java & Spring & SQL Java & Spring & Hibernate & SQL Java & .NET & SQL
How do I use this?
How do I use this?

Start screening within minutes with Adaface ready-to-go tests

Start screening within minutes with Adaface ready-to-go tests

1. Choose the most appropriate test for your role

2. Start inviting candidates to complete the assessment

3. Receive real time notifications and shortlist the best candidates

OR

Customize the test with multiple skills/ seniority levels according to your job description

Customize the test with multiple skills/ seniority levels according to your job description

1. Get a custom assessment from our library of 700+ skills within 48 hours

2. Start inviting candidates to complete the assesment

3. Receive real time notifications and shortlist the best candidates

What Are Conversational Assessments
What Are Conversational Assessments

Conversational assessments are the most candidate friendly way to get insights into a candidate's on-the-job skills and suitability for a role, while providing for a delightful candidate experience. Candidates love conversational assessments because they are fast, intuitive and feel like an interview rather than a test.

traditional assessments cons

Tired of traditional assessments with trick questions and low completion rates?

conversational assessments pros

Adaface conversational assessments are reflective of on-the-job skills and see an 86% completion rate as compared to ~50% for traditional assessment platforms.

Test multiple skills in a single assessment customized for your job description
Test multiple skills in a single assessment customized for your job description
Popular Guides
Favorieten van het beste talent van vandaag
TRY FOR FREE

(100% vrij om te beginnen, geen creditcard nodig)

Voorwaarden Privacy GDPR