- 博客(4)
- 收藏
- 关注
原创 【LeetCode-Python】136. Single Number
Given an array of integers, every element appears twice except for one. Find that single one.Note: Your algorithm should have a linear runtime complexity. Could you implement it without using extra me
2016-10-19 22:55:35 721
原创 【LeetCode-Python】292. 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 will be the
2016-10-19 11:31:03 601
原创 【LeetCode-Python】412. Fizz Buzz
Write a program that outputs the string representation of numbers from 1 to n.But for multiples of three it should output “Fizz” instead of the number and for the multiples of five output “Buzz”. For n
2016-10-19 09:36:25 2753
原创 【LeetCode-Python】344. Reverse String
Write a function that takes a string as input and returns the string reversed.Example: Given s = “hello”, return “olleh”.Solution[Python]:class Solution(object): def reverseString(self, s):
2016-10-09 09:26:52 638
空空如也
空空如也
TA创建的收藏夹 TA关注的收藏夹
TA关注的人