Problem database last updated: June 20, 2025

NNutanix logo

Nutanix Coding Interview Questions

58 problems · 3 Easy, 44 Medium, 11 Hard · Ranked #40 of 458

Difficulty breakdown

3 Easy

5% · avg 23%

44 Medium

76% · avg 59%

11 Hard

19% · avg 18%

Top topics

array
58.6%
string
20.7%
hash-table
20.7%
breadth-first-search
19%2.3x
matrix
15.5%1.8x
depth-first-search
15.5%1.7x

Interview profile

Based on 58 reported problems, Nutanix interviews are in line with industry averages - 19% Hard vs 18% overall. The majority (76%) of questions are Medium difficulty, which is typical for companies that want to see solid fundamentals without excessive trick questions.

Compared to the industry average, Nutanix puts unusual emphasis on monotonic-queue (5.2% of problems, 7.5x the industry average), segment-tree (3.4% of problems, 5.7x the industry average), queue (5.2% of problems, 3.6x the industry average). If you're short on time, these are the categories to double down on.

The most common topics are array (58.6%), string (20.7%), hash-table (20.7%), breadth-first-search (19%). Problems below are sorted by frequency, the ones at the top are asked most often.

All 58 problems

Check If Word Is Valid After Substitutions

Solve

Given a string s, determine if it is valid.

MediumVery Likely
stringstack

Online Majority Element In Subarray

Solve

Design a data structure that efficiently finds the majority element of a given subarray.

HardVery Likely
arraybinary-searchdesign

Maximum Sum of an Hourglass

Solve

You are given an m x n integer matrix grid.

MediumVery Likely
arraymatrixprefix-sum

Broken Calculator

Solve

There is a broken calculator that has the integer startValue on its display initially. In one operation, you can:

MediumVery Likely
mathgreedy

Minimum Processing Time

Solve

You have a certain number of processors, each having 4 cores. The number of tasks to be executed is four times the number of processors. Each task must be assig...

MediumVery Likely
arraygreedysorting

Detect Cycles in 2D Grid

Solve

Given a 2D array of characters grid of size m x n, you need to find if there exists any cycle consisting of the same value in grid.

MediumVery Likely
arraydepth-first-searchbreadth-first-search

Partitioning Into Minimum Number Of Deci-Binary Numbers

Solve

A decimal number is called deci-binary if each of its digits is either 0 or 1 without any leading zeros. For example, 101 and 1100 are deci-binary, while 112 an...

MediumVery Likely
stringgreedy

Car Fleet

Solve

There are n cars at given miles away from the starting mile 0, traveling to reach the mile target.

MediumVery Likely
arraystacksorting

Grumpy Bookstore Owner

Solve

There is a bookstore owner that has a store open for n minutes. You are given an integer array customers of length n where customers[i] is the number of the cus...

MediumVery Likely
arraysliding-window

Delivering Boxes from Storage to Ports

Solve

You have the task of delivering some boxes from storage to their ports using only one ship. However, this ship has a limit on the number of boxes and the total...

HardVery Likely
arraydynamic-programmingsegment-tree

Swap For Longest Repeated Character Substring

Solve

You are given a string text. You can swap two of the characters in the text.

MediumVery Likely
hash-tablestringsliding-window

LRU Cache

Solve

Design a data structure that follows the constraints of a Least Recently Used (LRU) cache.

MediumVery Likely
hash-tablelinked-listdesign

Pacific Atlantic Water Flow

Solve

There is an m x n rectangular island that borders both the Pacific Ocean and Atlantic Ocean. The Pacific Ocean touches the island's left and top edges, and the...

MediumVery Likely
arraydepth-first-searchbreadth-first-search

Merge Intervals

Solve

Given an array of intervals where intervals[i] = [starti, endi], merge all overlapping intervals, and return an array of the non-overlapping intervals that cove...

MediumLikely
arraysorting

Sliding Window Maximum

Solve

You are given an array of integers nums, there is a sliding window of size k which is moving from the very left of the array to the very right. You can only see...

HardLikely
arrayqueuesliding-window

Rotting Oranges

Solve

You are given an m x n grid where each cell can have one of three values:

MediumLikely
arraybreadth-first-searchmatrix

Group Anagrams

Solve

Given an array of strings strs, group the anagrams together. You can return the answer in any order.

MediumLikely
arrayhash-tablestring

Increasing Triplet Subsequence

Solve

Given an integer array nums, return true if there exists a triple of indices (i, j, k) such that i < j < k and nums[i] < nums[j] < nums[k]. If no such indices e...

MediumLikely
arraygreedy

Spiral Matrix

Solve

Given an m x n matrix, return all elements of the matrix in spiral order.

MediumLikely
arraymatrixsimulation

Two Sum

Solve

Given an array of integers nums and an integer target, return the indices of the two numbers that add up to target.

EasyLikely
arrayhash-map

Product of Array Except Self

Solve

Given an integer array nums, return an array answer such that answer[i] is equal to the product of all the elements of nums except nums[i].

MediumLikely
arrayprefix-sum

Search a 2D Matrix

Solve

You are given an m x n integer matrix matrix with the following two properties:

MediumLikely
arraybinary-searchmatrix

Set Matrix Zeroes

Solve

Given an m x n integer matrix matrix, if an element is 0, set its entire row and column to 0's.

MediumLikely
arrayhash-tablematrix

Decode String

Solve

Given an encoded string, return its decoded string.

MediumLikely
stringstackrecursion

First Missing Positive

Solve

Given an unsorted integer array nums. Return the smallest positive integer that is not present in nums.

HardLikely
arrayhash-table

Reverse Linked List II

Solve

Given the head of a singly linked list and two integers left and right where left <= right, reverse the nodes of the list from position left to position right,...

MediumLikely
linked-list

Valid Number

Solve

Given a string s, return whether s is a valid number.

HardLikely
string

Top K Frequent Elements

Solve

Given an integer array nums and an integer k, return the k most frequent elements. You may return the answer in any order.

MediumLikely
arrayhash-tabledivide-and-conquer

Maximum Frequency Stack

Solve

Design a stack-like data structure to push elements to the stack and pop the most frequent element from the stack.

HardLikely
hash-tablestackdesign

Binary Tree Maximum Path Sum

Solve

A path in a binary tree is a sequence of nodes where each pair of adjacent nodes in the sequence has an edge connecting them. A node can only appear in the sequ...

HardLikely
dynamic-programmingtreedepth-first-search

Number of Islands

Solve

Given an m x n 2D binary grid grid which represents a map of '1's (land) and '0's (water), return the number of islands.

MediumLikely
arraydepth-first-searchbreadth-first-search

Surrounded Regions

Solve

You are given an m x n matrix board containing letters 'X' and 'O', capture regions that are surrounded:

MediumLikely
arraydepth-first-searchbreadth-first-search

Best Time to Buy and Sell Stock

Solve

You are given an array prices where prices[i] is the price of a given stock on the ith day.

EasyLikely
arraydynamic-programming

Swap Nodes in Pairs

Solve

Given a linked list, swap every two adjacent nodes and return its head. You must solve the problem without modifying the values in the list's nodes (i.e., only...

MediumLikely
linked-listrecursion

Binary Tree Zigzag Level Order Traversal

Solve

Given the root of a binary tree, return the zigzag level order traversal of its nodes' values. (i.e., from left to right, then right to left for the next level...

MediumLikely
treebreadth-first-searchbinary-tree

Word Break

Solve

Given a string s and a dictionary of strings wordDict, return true if s can be segmented into a space-separated sequence of one or more dictionary words.

MediumLikely
arrayhash-tablestring

Word Ladder

Solve

A transformation sequence from word beginWord to word endWord using a dictionary wordList is a sequence of words beginWord -> s1 -> s2 -> ... -> sk such that:

HardLikely
hash-tablestringbreadth-first-search

Find Minimum in Rotated Sorted Array

Solve

Suppose an array of length n sorted in ascending order is rotated between 1 and n times. For example, the array nums = [0,1,2,4,5,6,7] might become:

MediumLikely
arraybinary-search

Longest Continuous Subarray With Absolute Diff Less Than or Equal to Limit

Solve

Given an array of integers nums and an integer limit, return the size of the longest non-empty subarray such that the absolute difference between any two elemen...

MediumLikely
arrayqueuesliding-window

Longest Palindromic Subsequence

Solve

Given a string s, find the longest palindromic subsequence's length in s.

MediumLikely
stringdynamic-programming

Reverse Nodes in k-Group

Solve

Given the head of a linked list, reverse the nodes of the list k at a time, and return the modified list.

HardLikely
linked-listrecursion

Merge k Sorted Lists

Solve

You are given an array of k linked-lists lists, each linked-list is sorted in ascending order.

HardLikely
linked-listdivide-and-conquerheap-priority-queue

Min Cost to Connect All Points

Solve

You are given an array points representing integer coordinates of some points on a 2D-plane, where points[i] = [xi, yi].

MediumLikely
arrayunion-findgraph

All Nodes Distance K in Binary Tree

Solve

Given the root of a binary tree, the value of a target node target, and an integer k, return an array of the values of all nodes that have a distance k from the...

MediumLikely
hash-tabletreedepth-first-search

Clone Graph

Solve

Given a reference of a node in a connected undirected graph.

MediumLikely
hash-tabledepth-first-searchbreadth-first-search

Amount of Time for Binary Tree to Be Infected

Solve

You are given the root of a binary tree with unique values, and an integer start. At minute 0, an infection starts from the node with value start.

MediumLikely
hash-tabletreedepth-first-search

Minimum Number of Swaps to Make the String Balanced

Solve

You are given a 0-indexed string s of even length n. The string consists of exactly n / 2 opening brackets '[' and n / 2 closing brackets ']'.

MediumLikely
two-pointersstringstack

Maximum Product of Three Numbers

Solve

Given an integer array nums, find three numbers whose product is maximum and return the maximum product.

EasyLikely
arraymathsorting

Jump Game II

Solve

You are given a 0-indexed array of integers nums of length n. You are initially positioned at index 0.

MediumLikely
arraydynamic-programminggreedy

Longest Common Subsequence

Solve

Given two strings text1 and text2, return the length of their longest common subsequence. If there is no common subsequence, return 0.

MediumLikely
stringdynamic-programming

Search in Rotated Sorted Array

Solve

There is an integer array nums sorted in ascending order (with distinct values).

MediumLikely
arraybinary-search

Trapping Rain Water

Solve

Given n non-negative integers representing an elevation map where the width of each bar is 1, compute how much water it can trap after raining.

HardLikely
arraytwo-pointersdynamic-programming

Add Two Numbers

Solve

You are given two non-empty linked lists representing two non-negative integers. The digits are stored in reverse order, and each of their nodes contains a sing...

MediumLikely
linked-listmathrecursion

Container With Most Water

Solve

You are given an integer array height of length n. There are n vertical lines drawn such that the two endpoints of the ith line are (i, 0) and (i, height[i]).

MediumLikely
arraytwo-pointersgreedy

Longest Palindromic Substring

Solve

Given a string s, return the longest palindromic substring in s.

MediumLikely
two-pointersstringdynamic-programming

3Sum

Solve

Given an integer array nums, return all the triplets [nums[i], nums[j], nums[k]] such that i != j, i != k, and j != k, and nums[i] + nums[j] + nums[k] == 0.

MediumLikely
arraytwo-pointerssorting

Course Schedule

Solve

There are a total of numCourses courses you have to take, labeled from 0 to numCourses - 1. You are given an array prerequisites where prerequisites[i] = [ai, b...

MediumLikely
depth-first-searchbreadth-first-searchgraph

Heaters

Solve

Winter is coming! During the contest, your first job is to design a standard heater with a fixed warm radius to warm all the houses.

MediumLikely
arraytwo-pointersbinary-search

How often are these problems asked?

Frequency scores are based on crowdsourced interview reports. A higher score means the problem has been reported more often in recent Nutanix interviews.

Very Likely

75-100%

Likely

50-74%

Sometimes

25-49%

Rare

0-24%

Preparing for your Nutanix coding interview

Nutanix interviews focus heavily on array, string, hash-table problems. If you're short on time, these are the categories to prioritize. The problems on this page are sorted by frequency, so start from the top and work your way down.

Beyond solving problems, practice explaining your approach. Nutanix interviewers care about your thought process - how you break down a problem, consider edge cases, and evaluate tradeoffs between solutions. A clean O(n) solution you can explain clearly beats an O(log n) solution you can't articulate.

Looking for more companies? Browse all 458 companies in our directory, or sharpen your fundamentals with our free data structure visualizers and AI-powered DSA tutor.

Frequently Asked Questions

What coding problems does Nutanix ask in interviews?add

Nutanix has been reported to ask 58 distinct coding problems. The most common topics are array, string, hash-table. 3 are Easy difficulty, 44 are Medium, and 11 are Hard. Problems are sorted by frequency - the ones at the top are asked most often.

How hard are Nutanix coding interviews?add

Based on 58 reported problems, Nutanix interviews are in line with industry averages - 19% Hard vs 18% overall. 76% of questions are Medium difficulty. Focus on the high-frequency Medium problems first, then work through the Hard ones.

How should I prepare for a Nutanix coding interview?add

Start with the highest-frequency problems listed on this page. Focus on the core topics: array, string, hash-table. Practice solving them under time pressure and explaining your approach out loud. Mock interviews with AI can simulate the real experience.

Other companies to explore

Ready to ace your Nutanix interview?

Simulate a real Nutanix coding interview with an AI interviewer. Get a scorecard with specific feedback on your problem-solving, code quality, and communication.

Simulate a Nutanix interview with AIarrow_forward