```
class Solution(object):
def kthSmallest(self, root, k):
arr = []
self.in_order(root, arr)
return arr[k-1]
def in_order(self, root, arr):
if not root:
return
self.in_order(root.left, arr)
arr.append(root.val)
self.in_order(root.right, arr)
```