Sara

  • Home

  • Tags

  • Categories

  • Archives

  • Search

LeetCode_Binary Tree Zigzag Level Order Traversal

Posted on 2019-03-04 | Edited on 2019-03-27 | In LeetCode

Binary Tree Zigzag Level Order Traversal

Given a binary tree, return the zigzag level order traversal of its nodes’ values. (ie, from left to right, then right to left for the next level and alternate between).(按层从左到右->从右到左遍历二叉树)

Read more »

LeetCode_Binary Tree Level Order Traversal

Posted on 2019-03-04 | In LeetCode

Binary Tree Level Order Traversal

Given a binary tree, return the level order traversal of its nodes’ values. (ie, from left to right, level by level).
(按层遍历二叉树)

Read more »

LeetCode_Symmetric Tree

Posted on 2019-03-04 | In LeetCode

Symmetric Tree

Given a binary tree, check whether it is a mirror of itself (ie, symmetric around its center).
(对称二叉树)

Read more »

LeetCode_Same Tree

Posted on 2019-02-27 | In LeetCode

Same Tree

Given two binary trees, write a function to check if they are the same or not. Two binary trees are considered the same if they are structurally identical and the nodes have the same value.
(判断二叉树是否相同)

Read more »

LeetCode_Recover Binary Search Tree

Posted on 2019-02-27 | In LeetCode

Recover Binary Search Tree

Two elements of a binary search tree (BST) are swapped by mistake. Recover the tree without changing its structure.
(复原二叉排序树)

Read more »

LeetCode_Validate Binary Search Tree

Posted on 2019-02-27 | In LeetCode

Validate Binary Search Tree

Given a binary tree, determine if it is a valid binary search tree (BST).
(判断是否为二叉排序树)

Assume a BST is defined as follows:

  1. The left subtree of a node contains only nodes with keys less than the node’s key.
  2. The right subtree of a node contains only nodes with keys greater than the node’s key.
  3. Both the left and right subtrees must also be binary search trees.
Read more »

LeetCode_Interleaving String

Posted on 2019-02-27 | In LeetCode

Interleaving String

Given s1, s2, s3, find whether s3 is formed by the interleaving of s1 and s2.
(判断s1 与 s2 相互插入可否组成 s3)

Read more »

LeetCode_Unique Binary Search Trees

Posted on 2019-02-27 | In LeetCode

Unique Binary Search Trees

Given an integer n, generate all structurally unique BST’s (binary search trees) that store values 1 … n.
(有效二叉查找(排序)树个数)

Read more »

LeetCode_Unique Binary Search Trees II

Posted on 2019-02-27 | In LeetCode

Unique Binary Search Trees II

Given an integer n, generate all structurally unique BST’s (binary search trees) that store values 1 … n.
(构建二叉查找(排序)树)

Read more »

LeetCode_Binary Tree Inorder Traversal

Posted on 2019-02-27 | Edited on 2019-03-15 | In LeetCode

Binary Tree Inorder Traversal

Given a binary tree, return the inorder traversal of its nodes’ values.
(中序遍历二叉树)

Read more »
1…101112…21

Sara Han

207 posts
4 categories
40 tags
© 2019 Sara Han
Powered by Hexo v3.8.0
|
Theme – NexT.Mist v6.4.2