Invert Binary Tree
Understand and solve the interview question "Invert Binary Tree".
We'll cover the following...
Description
In this lesson, your task is to invert a given binary tree, T
.
Let’s look at an example below:
main.swift
TreeNode.swift
import Swiftfunc invertTree(root: TreeNode?) -> TreeNode? {return root}
Invert binary tree exercise
...