Given a binary tree, determine if it is a valid binary search tree (BST).Assume a BST is defined as follows:The left subtree of a node contains only n...
分类:
编程语言 时间:
2015-05-21 22:32:43
阅读次数:
187
【题目】Given two stringssandt, determine if they are isomorphic.Two strings are isomorphic if the characters inscan be replaced to gett.All occurrences o...
分类:
其他好文 时间:
2015-05-21 19:18:04
阅读次数:
135
Given two stringssandt, determine if they are isomorphic.Two strings are isomorphic if the characters inscan be replaced to gett.All occurrences of a ...
分类:
其他好文 时间:
2015-05-21 12:16:37
阅读次数:
139
Given a linked list, determine if it has a cycle in it.Follow up:Can you solve it without using extra space?分析:用map记录是否出现过。用时:60ms 1 /** 2 * Definiti....
分类:
其他好文 时间:
2015-05-20 22:07:14
阅读次数:
145
Problem:高效率实现“字符串中是否有重复字符”
Implement an algorithm to determine if a string has all unique characters. What if you
can not use additional data structures?
#include
#include
#include
#include
#include
#include
#incl...
分类:
其他好文 时间:
2015-05-19 13:14:16
阅读次数:
119
examination questionsWrite an algorithm to determine if a number is "happy".A happy number is a number defined by the following process: Starting with...
分类:
移动开发 时间:
2015-05-19 10:21:02
阅读次数:
242
Problem:
Determine if a Sudoku is valid, according to: Sudoku Puzzles - The Rules.
The Sudoku board could be partially filled, where empty cells are filled with the character '.'.
A p...
分类:
编程语言 时间:
2015-05-19 00:53:17
阅读次数:
188
http://acm.timus.ru/problem.aspx?space=1&num=1057
1057. Amount of Degrees
Time limit: 1.0 second
Memory limit: 64 MB
Create a code to determine the amount of integers, lying in the set...
分类:
其他好文 时间:
2015-05-18 23:05:14
阅读次数:
237
https://leetcode.com/problems/valid-palindrome/Valid PalindromeGiven a string, determine if it is a palindrome, considering only alphanumeric characte...
分类:
编程语言 时间:
2015-05-18 18:46:26
阅读次数:
304
Write an algorithm to determine if a number is "happy".A happy number is a number defined by the following process: Starting with any positive integer...
分类:
移动开发 时间:
2015-05-18 16:31:56
阅读次数:
183