摘要: 题目描述: Given an integer n, return the number of trailing zeroes in n!. Note: Your solution should be in logarithmic time complexity. 思路: 求n的阶乘最后面连续的0的个 阅读全文
posted @ 2018-01-04 17:38 zlz099 阅读(97) 评论(0) 推荐(0) 编辑
摘要: 题目描述: Related to question Excel Sheet Column Title Given a column title as appear in an Excel sheet, return its corresponding column number. For examp 阅读全文
posted @ 2018-01-04 17:11 zlz099 阅读(154) 评论(0) 推荐(0) 编辑
摘要: 题目描述: Given a positive integer, return its corresponding column title as appear in an Excel sheet. For example: 思路: Excel序是这样的:A~Z, AA~ZZ, AAA~ZZZ, …… 阅读全文
posted @ 2018-01-04 16:54 zlz099 阅读(138) 评论(0) 推荐(0) 编辑
摘要: 题目描述: Given a binary tree, find its maximum depth. The maximum depth is the number of nodes along the longest path from the root node down to the fart 阅读全文
posted @ 2018-01-03 17:17 zlz099 阅读(123) 评论(0) 推荐(0) 编辑
摘要: 题目描述: Given a binary tree, check whether it is a mirror of itself (ie, symmetric around its center). For example, this binary tree [1,2,2,3,4,4,3] is 阅读全文
posted @ 2018-01-03 17:14 zlz099 阅读(147) 评论(0) 推荐(0) 编辑
摘要: 题目描述: Given a string, determine if it is a palindrome, considering only alphanumeric characters and ignoring cases. For example,"A man, a plan, a cana 阅读全文
posted @ 2018-01-03 17:13 zlz099 阅读(109) 评论(0) 推荐(0) 编辑
摘要: 题目描述: Given an array of integers, every element appears twice except for one. Find that single one. Note:Your algorithm should have a linear runtime c 阅读全文
posted @ 2018-01-03 17:11 zlz099 阅读(102) 评论(0) 推荐(0) 编辑
摘要: 题目描述: Given a string containing just the characters '(', ')', '{', '}', '[' and ']', determine if the input string is valid. The brackets must close i 阅读全文
posted @ 2017-12-29 16:11 zlz099 阅读(99) 评论(0) 推荐(0) 编辑
摘要: 题目描述: 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 阅读全文
posted @ 2017-12-29 16:08 zlz099 阅读(103) 评论(0) 推荐(0) 编辑
摘要: 题目描述: Given a sorted linked list, delete all duplicates such that each element appear only once. For example,Given 1->1->2, return 1->2.Given 1->1->2- 阅读全文
posted @ 2017-12-29 16:07 zlz099 阅读(107) 评论(0) 推荐(0) 编辑