All company sheets
Grafana Labs DSA interview questions
56 problems to practise before your Grafana Labs online test or coding round. Most widely asked first.
56
Questions
9
Easy
37
Medium
10
Hard
Commonly reported. Problems candidates often report from this company’s coding rounds. These are Astra’s own tags, not an official question list.
Grafana Labs is hiring · 29 open roles on Astra right nowView roles56 questions
- 1
Find All Numbers Disappeared in an Array (O(1) Space)
EasyArrayTagged at 7 companies - 2
Find the Maximum Number of Consecutive Ones
EasyArrayTagged at 7 companies - 3
Maximum Product Subarray
MediumArrayTagged at 7 companies - 4
3Sum Closest
MediumArrayTagged at 7 companies - 5
Spiral Matrix
MediumArrayTagged at 7 companies - 6
Find All Subsets (Power Set) of a Set
MediumRecursionTagged at 7 companies - 7
Flatten a Binary Tree to a Linked List
MediumRecursionTagged at 7 companies - 8
Find the H-Index of a Researcher's Citations
MediumBinary SearchTagged at 7 companies - 9
Find Smallest Common Element in All Rows
MediumBinary SearchTagged at 7 companies - 10
Find the Contiguous Subarray with the Largest Sum
MediumArrayTagged at 7 companies - 11
Find the Duplicate Number (O(1) Space)
MediumArrayTagged at 7 companies - 12
Solve the House Robber II Problem (Circular)
MediumArrayTagged at 7 companies - 13
Longest Subarray of 1s After Deleting One Element
MediumSliding WindowTagged at 7 companies - 14
Find K-Length Substrings With No Repeated Characters
MediumSliding WindowTagged at 7 companies - 15
Valid Anagram
EasyStringTagged at 6 companies - 16
Check if a Linked List is a Palindrome
EasyLinkedListTagged at 6 companies - 17
Remove All Linked List Elements with a Given Value
EasyLinkedListTagged at 6 companies - 18
Find the Sum of Last N Nodes of a Linked List
EasyLinkedListTagged at 6 companies - 19
Implement N-ary Tree Postorder Traversal
EasyTreeTagged at 6 companies - 20
Find the Maximum Depth of an N-ary Tree
EasyTreeTagged at 6 companies - 21
Find Kth Largest Element in a Data Stream
EasyTreeTagged at 6 companies - 22
Binary Tree Level Order Traversal
MediumTreeTagged at 6 companies - 23
Kth Smallest Element in a BST
MediumTreeTagged at 6 companies - 24
Count Vowels Permutation
MediumDPTagged at 6 companies - 25
Calculate Number of Car Fleets Approaching Destination
MediumStack and QueueTagged at 6 companies - 26
Reverse a Queue Using Only Standard Operations
MediumStack and QueueTagged at 6 companies - 27
Calculate the Sum of All Subarray Ranges
MediumStack and QueueTagged at 6 companies - 28
Clone an Undirected Graph Using BFS or DFS
MediumStack and QueueTagged at 6 companies - 29
Convert Binary Tree to a Circular Doubly Linked List
MediumLinkedListTagged at 6 companies - 30
Implement a Trie (Prefix Tree) - Search
MediumTreeTagged at 6 companies - 31
Implement a Magic Dictionary (Trie-based)
MediumTreeTagged at 6 companies - 32
Implement a Binary Heap (Min-Heap) - ExtractMin
MediumTreeTagged at 6 companies - 33
Implement Insertion into a Binary Search Tree (BST)
MediumTreeTagged at 6 companies - 34
Convert a Binary Search Tree to a Sorted Circular Doubly Linked List
MediumTreeTagged at 6 companies - 35
Find All Duplicate Subtrees in a Binary Tree
MediumTreeTagged at 6 companies - 36
Populate Next Right Pointers in Each Node II (Any Tree)
MediumTreeTagged at 6 companies - 37
Find the Index of the First Occurrence (strStr)
MediumStringTagged at 6 companies - 38
Find All Starting Indices of Anagrams in a String
MediumStringTagged at 6 companies - 39
Reorganize String to Avoid Adjacent Duplicates
MediumStringTagged at 6 companies - 40
Ad Server Campaign Injection
MediumIntervalsTagged at 6 companies - 41
Find Minimum Edit Distance Between Two Strings
HardRecursionTagged at 6 companies - 42
Find the Kth Smallest Pair Distance
HardBinary SearchTagged at 6 companies - 43
Find Maximum Running Time of N Computers
HardBinary SearchTagged at 6 companies - 44
Find the Smallest Good Base for a Number 'n'
HardBinary SearchTagged at 6 companies - 45
Find the Maximum Profit in Job Scheduling (DP + Binary Search)
HardArrayTagged at 6 companies - 46
Sliding Window Maximum
HardSliding WindowTagged at 6 companies - 47
Graph Valid Tree
MediumGraphTagged at 5 companies - 48
Minimum Genetic Mutation
MediumGraphTagged at 5 companies - 49
Word Search
MediumBacktrackingTagged at 5 companies - 50
Dijkstra’s Algorithm (Using Min Heap)
MediumGraphTagged at 5 companies - 51
Redis In-Memory Caching System
MediumDesignTagged at 5 companies - 52
LinkedIn Connection Suggestion
MediumGraphTagged at 5 companies - 53
Implement a Basic Calculator with Addition and Subtraction
HardStack and QueueTagged at 5 companies - 54
Scramble String
HardDPTagged at 4 companies - 55
Find Median from Data Stream
HardHeapTagged at 3 companies - 56
Shortest Distance from All Buildings
HardGraphTagged at 3 companies