# Walmart Labs Coding Interview Questions

> 152 DSA problems asked in Walmart Labs coding interviews and online assessments, sorted easiest first with hints. Free practice for placements on InternHack.

Canonical: https://www.internhack.in/learn/dsa/companies/walmart-labs
Last updated: 2026-11-28

152 DSA problems tagged as asked in Walmart Labs coding interviews and online assessments. Below are the first 100 of 152: 22 easy, 53 medium and 25 hard. Start with the easy ones, then move to medium. Practise free on InternHack and track your progress.

## Walmart Labs DSA problems, easiest first

1. [Add Binary](https://www.internhack.in/learn/dsa/problem/add-binary) (Easy)
2. [Best Time to Buy and Sell Stock](https://www.internhack.in/learn/dsa/problem/best-time-to-buy-and-sell-stock) (Easy)
3. [Count Elements With Maximum Frequency](https://www.internhack.in/learn/dsa/problem/count-elements-with-maximum-frequency) (Easy)
4. [Degree of an Array](https://www.internhack.in/learn/dsa/problem/degree-of-an-array) (Easy)
5. [Diameter of Binary Tree](https://www.internhack.in/learn/dsa/problem/diameter-of-binary-tree) (Easy)
6. [First Unique Character in a String](https://www.internhack.in/learn/dsa/problem/first-unique-character-in-a-string) (Easy)
7. [Linked List Cycle](https://www.internhack.in/learn/dsa/problem/linked-list-cycle) (Easy)
8. [Longest Common Prefix](https://www.internhack.in/learn/dsa/problem/longest-common-prefix) (Easy)
9. [Maximum Distance Between Unequal Words in Array I](https://www.internhack.in/learn/dsa/problem/maximum-distance-between-unequal-words-in-array-i) (Easy)
10. [Maximum Length Substring With Two Occurrences](https://www.internhack.in/learn/dsa/problem/maximum-length-substring-with-two-occurrences) (Easy)
11. [Middle of the Linked List](https://www.internhack.in/learn/dsa/problem/middle-of-the-linked-list) (Easy)
12. [Move Zeroes](https://www.internhack.in/learn/dsa/problem/move-zeroes) (Easy)
13. [Relative Sort Array](https://www.internhack.in/learn/dsa/problem/relative-sort-array) (Easy)
14. [Remove Duplicates from Sorted Array](https://www.internhack.in/learn/dsa/problem/remove-duplicates-from-sorted-array) (Easy)
15. [Remove Letter To Equalize Frequency](https://www.internhack.in/learn/dsa/problem/remove-letter-to-equalize-frequency) (Easy)
16. [Rising Temperature](https://www.internhack.in/learn/dsa/problem/rising-temperature) (Easy)
17. [Roman to Integer](https://www.internhack.in/learn/dsa/problem/roman-to-integer) (Easy)
18. [The Winner University](https://www.internhack.in/learn/dsa/problem/the-winner-university) (Easy)
19. [Two Sum](https://www.internhack.in/learn/dsa/problem/two-sum) (Easy)
20. [Valid Palindrome](https://www.internhack.in/learn/dsa/problem/valid-palindrome) (Easy)
21. [Valid Parentheses](https://www.internhack.in/learn/dsa/problem/valid-parentheses) (Easy)
22. [XOR Operation in an Array](https://www.internhack.in/learn/dsa/problem/xor-operation-in-an-array) (Easy)
23. [Asteroid Collision](https://www.internhack.in/learn/dsa/problem/asteroid-collision) (Medium)
24. [Basic Calculator II](https://www.internhack.in/learn/dsa/problem/basic-calculator-ii) (Medium)
25. [Binary Tree Right Side View](https://www.internhack.in/learn/dsa/problem/binary-tree-right-side-view) (Medium)
26. [Boats to Save People](https://www.internhack.in/learn/dsa/problem/boats-to-save-people) (Medium)
27. [Boundary of Binary Tree](https://www.internhack.in/learn/dsa/problem/boundary-of-binary-tree) (Medium)
28. [Capacity To Ship Packages Within D Days](https://www.internhack.in/learn/dsa/problem/capacity-to-ship-packages-within-d-days) (Medium)
29. [Circular Permutation in Binary Representation](https://www.internhack.in/learn/dsa/problem/circular-permutation-in-binary-representation) (Medium)
30. [Coin Change](https://www.internhack.in/learn/dsa/problem/coin-change) (Medium)
31. [Contiguous Array](https://www.internhack.in/learn/dsa/problem/contiguous-array) (Medium)
32. [Course Schedule](https://www.internhack.in/learn/dsa/problem/course-schedule) (Medium)
33. [Course Schedule II](https://www.internhack.in/learn/dsa/problem/course-schedule-ii) (Medium)
34. [Daily Temperatures](https://www.internhack.in/learn/dsa/problem/daily-temperatures) (Medium)
35. [Decode String](https://www.internhack.in/learn/dsa/problem/decode-string) (Medium)
36. [Design Hit Counter](https://www.internhack.in/learn/dsa/problem/design-hit-counter) (Medium)
37. [Diagonal Traverse](https://www.internhack.in/learn/dsa/problem/diagonal-traverse) (Medium)
38. [Find All Anagrams in a String](https://www.internhack.in/learn/dsa/problem/find-all-anagrams-in-a-string) (Medium)
39. [Find All Duplicates in an Array](https://www.internhack.in/learn/dsa/problem/find-all-duplicates-in-an-array) (Medium)
40. [Find K Pairs with Smallest Sums](https://www.internhack.in/learn/dsa/problem/find-k-pairs-with-smallest-sums) (Medium)
41. [Find Peak Element](https://www.internhack.in/learn/dsa/problem/find-peak-element) (Medium)
42. [Find the Winner of the Circular Game](https://www.internhack.in/learn/dsa/problem/find-the-winner-of-the-circular-game) (Medium)
43. [Flatten Nested List Iterator](https://www.internhack.in/learn/dsa/problem/flatten-nested-list-iterator) (Medium)
44. [Furthest Building You Can Reach](https://www.internhack.in/learn/dsa/problem/furthest-building-you-can-reach) (Medium)
45. [House Robber](https://www.internhack.in/learn/dsa/problem/house-robber) (Medium)
46. [Keys and Rooms](https://www.internhack.in/learn/dsa/problem/keys-and-rooms) (Medium)
47. [Koko Eating Bananas](https://www.internhack.in/learn/dsa/problem/koko-eating-bananas) (Medium)
48. [Kth Largest Element in an Array](https://www.internhack.in/learn/dsa/problem/kth-largest-element-in-an-array) (Medium)
49. [Longest Common Subsequence](https://www.internhack.in/learn/dsa/problem/longest-common-subsequence) (Medium)
50. [Longest Increasing Subsequence](https://www.internhack.in/learn/dsa/problem/longest-increasing-subsequence) (Medium)
51. [Longest Substring with At Least K Repeating Characters](https://www.internhack.in/learn/dsa/problem/longest-substring-with-at-least-k-repeating-characters) (Medium)
52. [Meeting Rooms II](https://www.internhack.in/learn/dsa/problem/meeting-rooms-ii) (Medium)
53. [Min Stack](https://www.internhack.in/learn/dsa/problem/min-stack) (Medium)
54. [Minimum Remove to Make Valid Parentheses](https://www.internhack.in/learn/dsa/problem/minimum-remove-to-make-valid-parentheses) (Medium)
55. [Nearest Exit from Entrance in Maze](https://www.internhack.in/learn/dsa/problem/nearest-exit-from-entrance-in-maze) (Medium)
56. [Next Greater Element II](https://www.internhack.in/learn/dsa/problem/next-greater-element-ii) (Medium)
57. [Next Greater Element III](https://www.internhack.in/learn/dsa/problem/next-greater-element-iii) (Medium)
58. [Non-decreasing Array](https://www.internhack.in/learn/dsa/problem/non-decreasing-array) (Medium)
59. [Number of Distinct Islands](https://www.internhack.in/learn/dsa/problem/number-of-distinct-islands) (Medium)
60. [Number of Islands](https://www.internhack.in/learn/dsa/problem/number-of-islands) (Medium)
61. [Palindromic Substrings](https://www.internhack.in/learn/dsa/problem/palindromic-substrings) (Medium)
62. [Partition Equal Subset Sum](https://www.internhack.in/learn/dsa/problem/partition-equal-subset-sum) (Medium)
63. [Perfect Squares](https://www.internhack.in/learn/dsa/problem/perfect-squares) (Medium)
64. [Permutation in String](https://www.internhack.in/learn/dsa/problem/permutation-in-string) (Medium)
65. [Product of Array Except Self](https://www.internhack.in/learn/dsa/problem/product-of-array-except-self) (Medium)
66. [Remove All Adjacent Duplicates in String II](https://www.internhack.in/learn/dsa/problem/remove-all-adjacent-duplicates-in-string-ii) (Medium)
67. [Remove K Digits](https://www.internhack.in/learn/dsa/problem/remove-k-digits) (Medium)
68. [Rotate Array](https://www.internhack.in/learn/dsa/problem/rotate-array) (Medium)
69. [Rotting Oranges](https://www.internhack.in/learn/dsa/problem/rotting-oranges) (Medium)
70. [Sort an Array](https://www.internhack.in/learn/dsa/problem/sort-an-array) (Medium)
71. [Sort Characters By Frequency](https://www.internhack.in/learn/dsa/problem/sort-characters-by-frequency) (Medium)
72. [Subarray Sum Equals K](https://www.internhack.in/learn/dsa/problem/subarray-sum-equals-k) (Medium)
73. [The Maze](https://www.internhack.in/learn/dsa/problem/the-maze) (Medium)
74. [Top K Frequent Elements](https://www.internhack.in/learn/dsa/problem/top-k-frequent-elements) (Medium)
75. [Top K Frequent Words](https://www.internhack.in/learn/dsa/problem/top-k-frequent-words) (Medium)
76. [Binary Tree Maximum Path Sum](https://www.internhack.in/learn/dsa/problem/binary-tree-maximum-path-sum) (Hard)
77. [Candy](https://www.internhack.in/learn/dsa/problem/candy) (Hard)
78. [Count Different Palindromic Subsequences](https://www.internhack.in/learn/dsa/problem/count-different-palindromic-subsequences) (Hard)
79. [Count Good Triplets in an Array](https://www.internhack.in/learn/dsa/problem/count-good-triplets-in-an-array) (Hard)
80. [Distinct Subsequences](https://www.internhack.in/learn/dsa/problem/distinct-subsequences) (Hard)
81. [Find Median from Data Stream](https://www.internhack.in/learn/dsa/problem/find-median-from-data-stream) (Hard)
82. [First Missing Positive](https://www.internhack.in/learn/dsa/problem/first-missing-positive) (Hard)
83. [Largest Rectangle in Histogram](https://www.internhack.in/learn/dsa/problem/largest-rectangle-in-histogram) (Hard)
84. [LFU Cache](https://www.internhack.in/learn/dsa/problem/lfu-cache) (Hard)
85. [Max Stack](https://www.internhack.in/learn/dsa/problem/max-stack) (Hard)
86. [Maximum Number of Tasks You Can Assign](https://www.internhack.in/learn/dsa/problem/maximum-number-of-tasks-you-can-assign) (Hard)
87. [Median of Two Sorted Arrays](https://www.internhack.in/learn/dsa/problem/median-of-two-sorted-arrays) (Hard)
88. [Meeting Rooms III](https://www.internhack.in/learn/dsa/problem/meeting-rooms-iii) (Hard)
89. [Merge k Sorted Lists](https://www.internhack.in/learn/dsa/problem/merge-k-sorted-lists) (Hard)
90. [Minimum Number of Operations to Make Arrays Similar](https://www.internhack.in/learn/dsa/problem/minimum-number-of-operations-to-make-arrays-similar) (Hard)
91. [Minimum Window Substring](https://www.internhack.in/learn/dsa/problem/minimum-window-substring) (Hard)
92. [N-Queens II](https://www.internhack.in/learn/dsa/problem/n-queens-ii) (Hard)
93. [Number of Islands II](https://www.internhack.in/learn/dsa/problem/number-of-islands-ii) (Hard)
94. [Number of Ways to Separate Numbers](https://www.internhack.in/learn/dsa/problem/number-of-ways-to-separate-numbers) (Hard)
95. [Reconstruct Itinerary](https://www.internhack.in/learn/dsa/problem/reconstruct-itinerary) (Hard)
96. [Reverse Nodes in k-Group](https://www.internhack.in/learn/dsa/problem/reverse-nodes-in-k-group) (Hard)
97. [Trapping Rain Water](https://www.internhack.in/learn/dsa/problem/trapping-rain-water) (Hard)
98. [Trapping Rain Water II](https://www.internhack.in/learn/dsa/problem/trapping-rain-water-ii) (Hard)
99. [Wildcard Matching](https://www.internhack.in/learn/dsa/problem/wildcard-matching) (Hard)
100. [Word Ladder](https://www.internhack.in/learn/dsa/problem/word-ladder) (Hard)

## Prepare for the rest of the Walmart Labs process

- [Aptitude questions by company](https://www.internhack.in/learn/aptitude/companies)
- [Technical interview questions](https://www.internhack.in/learn/interview)
- [Free ATS resume check](https://www.internhack.in/ats-score/try), no signup

## Other companies

- [Google](https://www.internhack.in/learn/dsa/companies/google) (2217)
- [Amazon](https://www.internhack.in/learn/dsa/companies/amazon) (1938)
- [Meta](https://www.internhack.in/learn/dsa/companies/meta) (1387)
- [Microsoft](https://www.internhack.in/learn/dsa/companies/microsoft) (1352)
- [Bloomberg](https://www.internhack.in/learn/dsa/companies/bloomberg) (1173)
- [Tiktok](https://www.internhack.in/learn/dsa/companies/tiktok) (383)
- [Uber](https://www.internhack.in/learn/dsa/companies/uber) (381)
- [Apple](https://www.internhack.in/learn/dsa/companies/apple) (356)
- [Oracle](https://www.internhack.in/learn/dsa/companies/oracle) (340)
- [Goldman Sachs](https://www.internhack.in/learn/dsa/companies/goldman-sachs) (270)
- [Adobe](https://www.internhack.in/learn/dsa/companies/adobe) (227)
- [TCS](https://www.internhack.in/learn/dsa/companies/tcs) (217)
- [Salesforce](https://www.internhack.in/learn/dsa/companies/salesforce) (189)
- [Linkedin](https://www.internhack.in/learn/dsa/companies/linkedin) (180)
- [Zoho](https://www.internhack.in/learn/dsa/companies/zoho) (179)
- [IBM](https://www.internhack.in/learn/dsa/companies/ibm) (170)
- [Infosys](https://www.internhack.in/learn/dsa/companies/infosys) (158)
- [Accenture](https://www.internhack.in/learn/dsa/companies/accenture) (144)
- [Nvidia](https://www.internhack.in/learn/dsa/companies/nvidia) (137)
- [Yandex](https://www.internhack.in/learn/dsa/companies/yandex) (134)
- [DE Shaw](https://www.internhack.in/learn/dsa/companies/de-shaw) (124)
- [Visa](https://www.internhack.in/learn/dsa/companies/visa) (124)
- [Flipkart](https://www.internhack.in/learn/dsa/companies/flipkart) (117)
- [Paypal](https://www.internhack.in/learn/dsa/companies/paypal) (106)

## Related

- [Home](https://www.internhack.in/)
- [Learn](https://www.internhack.in/learn)
- [DSA by company](https://www.internhack.in/learn/dsa/companies)
