Codility is a coding platform that Microsoft uses for its Online Assessment. The Microsoft Codility Test is an online programming exam later reviewed by a Microsoft (MS) reviewer. On this test, you will typically receive a combination of 3 coding questions to be solved in 60-90 mins.
The Microsoft Online Assessment, also called the Online Technical Screen (OTS), is one of the first stages of the hiring process for software engineer roles. It will mostly involve a Codility exam, a phone interview, or both.
Your code will be graded automatically depending on its efficiency with all possible inputs:
When reviewed, your code will be assessed based on your understanding of the solution and on how optimal it is.
Microsoft online test questions will generally assess basic algorithm and data structure knowledge. On the Codility test, question types may be:
You will also be expected to answer questions related to computer subjects
Practicing all these topics may seem like a lot, but once you practice the most common Microsoft coding questions you will be able to save tons of time and effort.
You’ll be given the option to choose your preferred programming language before you begin the test. Therefore, when practicing for the Microsoft Codility Assessment, we recommend choosing the language you prefer to code with.
Microsoft’s coding interview questions are easy-medium on the first round Codility test or phone screen. Their difficulty also depends on your experience level and the specific role you’re applying for.
The main challenges here are:
Because of this, some people finish this test with blank answers and fail to pass Microsoft's code review.
Do you still have questions about Microsoft's Codility test? Check these Codility test FAQs
Try solving some of the most popular Microsoft online assessment questions available on our prep course:
1. Bubble Sort
Given an Integer N and a list arr. Sort the array using bubble sort algorithm.
Example:
Input:
N = 5
arr[] = {4, 1, 3, 9, 7}
Output:
1 3 4 7 9
2. Search an Element in Sorted and Rotated Array
Given a sorted and rotated array A of N distinct elements which is rotated at some point, and given an element K, find the index of the given element K in the array A.
Example:
Input:
N = 9
A[] = {5, 6, 7, 8, 9, 10, 1, 2, 3}
K = 10
Output: 5
Explanation: 10 is found at index 5.
3. Longest Consecutive Subsequence
Given an array A of integers, find the length of the longest sub-sequence so that elements in the sub-sequence are consecutive integers. The consecutive numbers can be in any order.
Example:
Input: N = 7, A[ ] = {1, 9, 3, 10, 4, 20, 2}
Output: 4
Explanation: The subsequent 1, 3, 4, 2 is the longest subsequence of consecutive elements.
4. Kadane's Algorithm
Given an array arr of N integers, find the contiguous sub-array with the maximum sum.
Example:
Input:
N = 5
Arr[ ] = {1, 2, 3, -2, 5}
Output:
9
Get detailed answers & access to over 312 Microsoft Codility practice questions on our full Microsoft Codility Prep Course.
Learn how not to leave any blank questions because of time constraints
It may be difficult and sometimes unrealistic to come up with the optimal solution for all coding questions given to you under time limits. To ensure you provide the best possible solution on time:
Practice data structures and algorithms thoroughly
Practice all types of coding questions asked on online assessments, especially strings and lists questions that arfrequently asked in Microsoft's Codility test and coding interviews. The more programming questions you solve, the better be better prepared.
Focus on the how as opposed to the what
Practicing the vast number of coding questions available on the web may take a lot of time and energy. To get the most out of your practice time, use practice resources that provide examples of optimal solutions to receive feedback regarding your answer and learn how to improve it. It will sharpen your ability to:
In our preparation pack, you’ll get access to a thorough prep course covering all question types found on Microsoft’s actual Codility test.
All on one online coding platform.
There are MANY different practice resources when it comes to coding interviews. Here is a list of the best practice resources for your upcoming Microsoft coding test. The idea is to get familiar with the program, learn solving strategies, and improve your coding skills:
The Codility platform
Take the (free) Codility sample test to boost familiarity with the coding platform and reduce stress on the Microsoft Codility test. Note that Codility test questions are usually quite different (mostly easier) than the questions asked by Microsoft. Yet, exploring the platform is recommended to ensure you know how to use it before the exam.
Leetcode Questions
The free practice questions in this Microsoft Leetcode Thread are great for checking that you are familiar with the type of questions people recently received on their Microsoft Codility Test. However, the solutions are written by users and can often be inaccurate. In addition, it lacks more in-depth explanations that are vital for learning how you can improve.
1. Communicate your thought process
It is important to Communicate your rationale and write comments during the OA when possible. This is especially important for Microsoft’s First Round OA since it may not involve personal interaction with the reviewer. Here are a few tips for that:
2. Ask clarification questions
If possible, the first step when approaching a problem should be asking important (but not excessive) clarification questions. What if you can’t ask any questions? No problem. Write your questions in a comment, along with the appropriate adjustments that are needed for each case scenario.
3. Describe the efficiency of your code
Show the reviewer you fully understand your solution by commenting on your code’s time and space complexity and its benefits and drawbacks.
You’ll receive a link 1-2 days before the scheduled interview. Feel free to open the link and read the instructions, this doesn’t mean you’ll have to start the test.
Codility usually requires turning on your camera, so be sure to be fully dressed, and if you thought about cheating - you may want to reconsider that.
You can use websites and books unless instructed otherwise by the recruiter.
You will not be able to stop the timer. Your code will be saved automatically throughout the test, even if you close the browser window and open it again.
Codility Usually records the whole history, including runs and corrections. This does NOT mean you have to be perfect- the opposite is true. Mistakes tell the reviewer about your ability to work your way to the solution.
When finishing a coding task, clicking “submit” will not allow you to go back and modify your code.
Make sure you visit your thorough prep guides for the Google Software Engineer Interview and Amazon Online Coding Assessment.