摘要: 题目 Binary Tree Level Order Traversal II通过率30.6%难度EasyGiven a binary tree, return thebottom-up level ordertraversal of its nodes' values. (ie, from ... 阅读全文
posted @ 2014-12-13 22:54 pku_min 阅读(150) 评论(1) 推荐(0)
摘要: 题目Same Tree通过率42.0%难度EasyGiven two binary trees, write a function to check if they are equal or not.Two binary trees are considered equal if they are ... 阅读全文
posted @ 2014-12-13 17:12 pku_min 阅读(141) 评论(0) 推荐(0)
摘要: 题目Pow( x, n)通过率26.2%难度MediumImplement pow(x,n). 初步构想:开始拿到题目就以为是简单的求幂运算,一直迭代乘法就可以了,事实证明,想法过于简单!!结果自己给自己挖了个坑,根本没有考虑到数的大小以及溢出的问题,自己默认n为正数了,要注意幂指数为负数的情况是... 阅读全文
posted @ 2014-12-13 16:57 pku_min 阅读(192) 评论(0) 推荐(0)