leetcode 刷题题解
文章平均质量分 59
swbcos
这个作者很懒,什么都没留下…
展开
-
leetcode_java_nim game
问题如下:You are playing the following Nim Game with your friend: There is a heap of stones on the table, each time one of you take turns to remove 1 to 3 stones. The one who removes the last stone wi原创 2015-11-25 14:57:29 · 281 阅读 · 0 评论 -
leetcode_java_twosum
问题:Given an array of integers, find two numbers such that they add up to a specific target number.The function twoSum should return indices of the two numbers such that they add up to the ta原创 2015-11-25 13:27:20 · 225 阅读 · 0 评论 -
leetcode_java_adddigits
题目如下:Given a non-negative integer num, repeatedly add all its digits until the result has only one digit.For example:Given num = 38, the process is like: 3 + 8 = 11, 1 + 1 = 2. Since原创 2015-11-25 22:07:52 · 322 阅读 · 0 评论 -
leetcode_java_Longest Substring Without Repeating Characters
问题描述:Given a string, find the length of the longest substring without repeating characters. For example, the longest substring without repeating letters for "abcabcbb" is "abc", which the length i原创 2015-11-27 16:16:06 · 261 阅读 · 0 评论