码迷,mamicode.com
首页 >  
搜索关键字:nearly prime numbers    ( 9679个结果
Leetcode:Combination Sum 子集和问题
Combination Sum:Given a set of candidate numbers (C) and a target number (T), find all unique combinations inCwhere the candidate numbers sums toT.The...
分类:其他好文   时间:2014-06-28 22:48:01    阅读次数:256
String build-in function - len
len is a build-in function that returns the numbers of characters in a string: Since we started counting at zero, the last index should be 5...
分类:其他好文   时间:2014-06-21 08:17:22    阅读次数:243
Leetcode:Triangle 三角形塔最小路径和
Triangle:Given a triangle, find the minimum path sum from top to bottom. Each step you may move to adjacent numbers on the row below.For example, give...
分类:其他好文   时间:2014-06-21 07:02:07    阅读次数:203
Leetcode:Combination Sum
Description:Given a set of candidate numbers (C) and a target number (T), find all unique combinations inCwhere the candidate numbers sums toT.Thesame...
分类:其他好文   时间:2014-06-21 06:55:48    阅读次数:200
Leetcode: Combination Sum
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 same repeate...
分类:其他好文   时间:2014-06-20 23:37:29    阅读次数:195
Careercup | Chapter 5
5.1 You are given two 32-bit numbers, N andM, and two bit positions, i and j. Write a method to insert M into Nsuch that M starts at bit j and ends at...
分类:其他好文   时间:2014-06-20 13:51:09    阅读次数:149
[LeetCode ] Two Sum
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 nu...
分类:其他好文   时间:2014-06-18 10:17:40    阅读次数:174
LeetCode: Permutations II 题解
Given a collection of numbers that might contain duplicates, return all possible unique permutations.For example,[1,1,2]have the following unique perm...
分类:其他好文   时间:2014-06-18 09:33:28    阅读次数:181
c语言实现判断一个数是否是素数
就是判断一个数是否是素数,网上很多版本,我觉得都有点问题,今天一个朋友问我这个问题,我才知道,现在我就贴出自己的代码,很有用哦!! #include #include  int Prime(unsigned int a)  {    unsigned int i;    int k=0;    if (a==1) k=1;     else for(i=2;i     if(a%...
分类:编程语言   时间:2014-06-18 07:30:59    阅读次数:210
[leetcode] 2. Add Two Numbers
You are given two linked lists representing two non-negative numbers. The digits are stored in reverse order and each of their nodes contain a single ...
分类:其他好文   时间:2014-06-17 23:38:04    阅读次数:341
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!