min depth

recursive way