小小程序媛  
得之坦然,失之淡然,顺其自然,争其必然
上一页 1 ··· 9 10 11 12 13 14 15 16 17 ··· 34 下一页

2015年10月9日

摘要: 题目Given numRows, generate the first numRows of Pascal’s triangle.For example, given numRows = 5, Return分析构建数字金字塔,由上图可以清楚的找到规律。该题目可用递归实现!比较简单~... 阅读全文
posted @ 2015-10-09 21:22 Coding菌 阅读(115) 评论(0) 推荐(0) 编辑
 
摘要: 题目Write an algorithm to determine if a number is “happy”.A happy number is a number defined by the following process: Starting with any posit... 阅读全文
posted @ 2015-10-09 21:08 Coding菌 阅读(154) 评论(0) 推荐(0) 编辑
 
摘要: 简单的抓取网页import urllib.request url="http://google.cn/" response=urllib.request.urlopen(url) #返回文件对象page=response.read()直接将URL保存为本地文件impor... 阅读全文
posted @ 2015-10-09 20:04 Coding菌 阅读(557) 评论(0) 推荐(0) 编辑
 
摘要: 一、cpu信息cpu信息存储在/proc文件系统的cpuinfo(/proc/cpuinfo)文件里,可以直接查看这个文件以获得cpu信息,所列字段解释如下:processor : 核心编号,如:0,1,2,3等。 vendor_id : ... 阅读全文
posted @ 2015-10-09 10:49 Coding菌 阅读(2851) 评论(0) 推荐(0) 编辑

2015年10月8日

摘要: 题目Reverse a linked list from position m to n. Do it in-place and in one-pass.For example: Given 1->2->3->4->5->NULL, m = 2 and n = 4,return 1... 阅读全文
posted @ 2015-10-08 16:37 Coding菌 阅读(169) 评论(0) 推荐(0) 编辑
 
摘要: 题目Given a collection of integers that might contain duplicates, nums, return all possible subsets.Note: Elements in a subset must be in non-d... 阅读全文
posted @ 2015-10-08 13:32 Coding菌 阅读(111) 评论(0) 推荐(0) 编辑

2015年10月7日

摘要: 题目Given a 2D board and a word, find if the word exists in the grid.The word can be constructed from letters of sequentially adjacent cell, wh... 阅读全文
posted @ 2015-10-07 18:18 Coding菌 阅读(183) 评论(0) 推荐(0) 编辑

2015年10月5日

摘要: 题目Given two words word1 and word2, find the minimum number of steps required to convert word1 to word2. (each operation is counted as 1 step.... 阅读全文
posted @ 2015-10-05 14:38 Coding菌 阅读(147) 评论(0) 推荐(0) 编辑

2015年10月4日

摘要: 题目Given a collection of candidate numbers (C) and a target number (T), find all unique combinations in C where the candidate numbers sums to ... 阅读全文
posted @ 2015-10-04 17:28 Coding菌 阅读(104) 评论(0) 推荐(0) 编辑
 
摘要: 题目Given a set of candidate numbers (C) and a target number (T), find all unique combinations in C where the candidate numbers sums to T.The s... 阅读全文
posted @ 2015-10-04 17:03 Coding菌 阅读(121) 评论(0) 推荐(0) 编辑
上一页 1 ··· 9 10 11 12 13 14 15 16 17 ··· 34 下一页