# Amazon

Questions asked in Amazon

Easy

# Implement Currying

Create a function `sum` that implements currying. Currying is a transformation of functions that translates a function from being callable as f(x, y, ...

Medium

# Feedback Stars

Create a feedback rating component that takes in a number of stars and outputs the corresponding star SVGs on the output window. When the user clicks ...

Medium

# Polyfills

A polyfill is a code snippet (in terms of javascript web architecture) used for modern world functionalities on older browsers that do not implement i...

Easy

# Branch Sums in a Binary Tree

Given a Binary Tree, compute the sum of all the branches in the tree. 1 branch is the path from the root to a leaf.

Easy

# Memoization

Memoization is a way for a function to remember or cache the results. Given an expensive function that takes a long time to compute for the same resul...

Easy

# Job Feed

Create a Job Feed page where the latest job postings are fetched from the Hackernews API. On clicking the job posting, the user should be able to land...

Medium

# Folder Structure

Given a data object resembling a folder structure, create a folder structure UI resembling that of VS code with appropriate functionalities.

Medium

# Toasts And Notifications

Toasts are the small little notification messages that popup on front-end applications to notify the user of some current actions that have happened. ...

Medium

# Find Successor

Given the root of a binary tree and a node in it, return the in-order successor of that node in the BST. If the given node has no in-order successor i...

Medium

# Kth Largest in a BST

Find Kth largest in a BST - Given a BST and a number k, find the kth largest element in the BST.

Easy

# String Compression

Given a string of alphabets (from a to z), Print the count of the character appearing in the string right next to it. This is also called Run Length E...

Easy

# Binary Search

Given an array of sorted integers in ascending order, and a target integer, write a function to search target in nums array. If target exists, return ...

Easy

# Smallest Difference

Given two arrays of integers, find the pair of values (one value in each array) with the smallest (non-negative) difference.

Easy

# Countries List with Debounce

Debouncing is a method of preventing a function from being invoked too often, and instead of waiting a certain amount of time until it was last called...

Medium

# BST Construction

Construct a Binary Search Tree and implement that implements insert, search, traverse and delete methods.

Easy

# Depth First Search

Depth-first search (DFS) is an algorithm for traversing or searching tree or graph data structures. The algorithm starts at the root node (selecting s...

Medium

# Minimum Number Of Coins To Make Change

Given an array of coins or denominations and a target sum, calculate the minimum number of coins required to match the total. Note that the coins arra...

Medium

# Levenshtein Distance

Given 2 strings, find the minimum number of operations required to change one string to the other. An operation is defined as either replacement of a ...

Easy

# Nth Fibonacci

Given an integer n, return the nth Fibonacci number. In mathematics, the Fibonacci numbers form a sequence called the Fibonacci sequence - In which ea...