Skip to main content
Kth Smallest Element in a BST | AlgoCracked
AlgoCracked
ProblemsKth Smallest Element in a BST
Medium70.0% acceptance
Blind75TreeDfsBinary Search Tree

Kth Smallest Element in a BST

Given the root of a binary search tree and an integer k , return the k -th smallest value (1-indexed). Input format Input is [root, k] , e.g. [[3,1,4,null,2],1] . TreeNode is predefined.

Loading workspace…