flattern tree