Coding Questions (2021)- MyKaarma, Cred


Applied through Career Page.

The first round consisted of an Online exam comprising of 2 sections, one was of MCQ’s and the other was a coding round.

Section 1: 20 MCQ on mix DS/Algo

Section 2: 3 Coding Question

  1. We have n jobs, where every job is scheduled to be done from startTime[i] to endTime[i], obtaining a profit of profit[i].You’re given the startTime, endTime and profit arrays, return the maximum profit you can take such that there are no two jobs in the subset with an overlapping time range. If you choose a job that ends at a time X you will be able to start another job that starts at the time X.
Input: startTime = [1,2,3,3], endTime = [3,4,5,6], profit = [50,10,40,70]
Output: 120

Leetcode Hard: Useful Link

2. Vipul writes numbers from N to 2 on paper. Now he takes number N and strikes of all its proper divisors. Next, he does the same with the largest number that is still not stricken(i.e strikes its proper divisors ). He does this so on further number could be stricken. The task is to find the number of numbers left unstricken. (A little thought gives out the answer to be (N+1)/2)

3. Count Inversions in an array | (Using Merge Sort)

Useful Link


Applied through Referral

Only 2 questions I got in the coding round.

  1. Count of words

Given a file with text paragraphs, print the count of unique words. (the logic should be case-insensitive)

Hint: Break using space in C++( Strtok)

2. Given a list of integers, reorder them in such a way that the even numbers come at even positions (0-based indexing), and the odd numbers come at odd position, with their relative order being the same as in the original list. If the number of even numbers is greater than odd numbers (or vice-versa), the extra ones should be at the end.

Input: [42, 24, 64, 83, 12, 6, 21, 55]Output: [42, 83, 24, 21, 64, 55, 12, 6]

Hint: Store all positions of odd,even and print accordingly.




Software Engineer 👨‍💻

Love podcasts or audiobooks? Learn on the go with our new app.

Download stock prices with Python

Stride Tech Talk: David A. Black

Cross-Origin Resource Sharing (CORS) in Depth

Dtube Hardfork Patch notes, Vote tipping and Improvements.

Containerized Automated Tests in Azure DevOps

Nutanix Data Pipelines and AI for Developers

Top 12 reasons why outsourcing software development is so successful

Linux and Git Unplugged

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store
Akash Kumar

Akash Kumar

Software Engineer 👨‍💻

More from Medium

Interview Experiences Series — TapClicks

9 Common Interview Questions For Fresher That You Shouldn’t Ignore.

Interview Questions For Fresher

Good Guidance can make your Dream come True!

My Interview Experience at