ancientor v (SNode val _ tl tr)
    | v < val        = ancientor v tl
    | otherwise      = ancientor v (sinsTree val tr)
ancientor v (SNode val _ tl tr)
    | v < val        = ancientor v tl
    | otherwise      = ancientor v (sinsTree val tr)
ancientor v (SNode val _ tl tr)
    | v < val        = ancientor v tl
    | otherwise      = ancientor v (sinsTree val tr)