12 2014 档案
摘要:题目Roman to Integer通过率34.2%难度EasyGiven a roman numeral, convert it to an integer.Input is guaranteed to be within the range from 1 to 3999.首先来看一下罗马数字的编...
阅读全文
摘要:题目Remove Duplicates from Sorted Array通过率31.9%难度EasyGiven a sorted array, remove the duplicates in place such that each element appear onlyonceand retu...
阅读全文
摘要:题目Remove Duplicates from Sorted List通过率34.4%难度EasyGiven a sorted linked list, delete all duplicates such that each element appear onlyonce.For example...
阅读全文
摘要:题目Maximum Depth of Binary Tree通过率44.2%难度EasyGiven a binary tree, find its maximum depth.The maximum depth is the number of nodes along the longest pat...
阅读全文
摘要:题目Reverse Integer通过率34.2%难度EasyReverse digits of an integer.Example1:x = 123, return 321Example2:x = -123, return -321click to show spoilers.Have you ...
阅读全文
摘要:题目 Binary Tree Level Order Traversal II通过率30.6%难度EasyGiven a binary tree, return thebottom-up level ordertraversal of its nodes' values. (ie, from ...
阅读全文
摘要:题目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 ...
阅读全文
摘要:题目Pow( x, n)通过率26.2%难度MediumImplement pow(x,n). 初步构想:开始拿到题目就以为是简单的求幂运算,一直迭代乘法就可以了,事实证明,想法过于简单!!结果自己给自己挖了个坑,根本没有考虑到数的大小以及溢出的问题,自己默认n为正数了,要注意幂指数为负数的情况是...
阅读全文
摘要:水平实在太low了,尤其是代码能力,一直以屌丝女程序猿为宏图目标,突然发现只成功了一半-屌丝女。 从今天开始code,每天两道题。 记录于此,以勉于己。 2014.12.12 ...
阅读全文
浙公网安备 33010602011771号