Search⌘ K

DIY: Range Sum of BST

Explore how to compute the sum of values within a given range in a binary search tree using Go. This lesson helps you implement a function to solve real-world coding problems faced by Amazon, preparing you for related interview questions.

Problem statement

For this challenge, you are given the root node of a binary search tree and two values: low and high. Your task is to return the sum of the values of all nodes in BST that are value between ...