码迷,mamicode.com
首页 >  
搜索关键字:palindrome numbers    ( 9163个结果
Leetcode: Valid Palindrome
Given a string, determine if it is a palindrome, considering only alphanumeric characters and ignoring cases.For example,"A man, a plan, a canal: Pana...
分类:其他好文   时间:2014-09-19 06:35:45    阅读次数:233
POJ2739_Sum of Consecutive Prime Numbers【筛法求素数】【枚举】
POJ2739_Sum of Consecutive Prime Numbers【筛法求素数】【枚举】...
分类:其他好文   时间:2014-09-18 23:51:14    阅读次数:237
【POJ2196】Specialized Four-Digit Numbers(暴力打表)
一道水题,只要会复制粘贴就好! 1 #include 2 #include 3 #include 4 #include 5 #include 6 #include 7 #include 8 #include 9 #include 10 #include 11 12 #define P...
分类:其他好文   时间:2014-09-18 23:42:34    阅读次数:176
poj3252(Round Numbers)
题目地址:Round Numbers题目大意: “Round Numbers” 是一个十进制的数转化为二进制,如果在二进制中 “0”的个数不小于“1”的个数,就称为“Round Numbers” 。本题求出n到m区间(闭区间)的“Round Numbers” 有多少个。解题思路: 排列组合的公式.....
分类:其他好文   时间:2014-09-18 22:04:04    阅读次数:145
ctrip的两道笔试题
第一个问题可以抽象为这样:给定一个数组A,和一个数t,用数组里的一些数求和得到t,数组里的数可以重复使用,写一个算法,使得使用A中最少的数来表示t。比如:[2,4,6,9],18==>[9,9]dfs问题//numbers要从大到小,一个sort搞定,result存放结果bool dfs(vecto...
分类:其他好文   时间:2014-09-18 22:02:24    阅读次数:162
UVA 763 Fibinary Numbers
题意讲某个二进制按照规则每一位对应斐波那契数生成新的数字,然后2个数字求和。再求由该规则生成的二进制串。并且要求尽量用更大项的fib数(题目提示不能由连续的1就是2个连续的1(11)不如100更优)用大数处理出100项fib。然后模拟交替置位位0或者1,输出#include #include #in...
分类:其他好文   时间:2014-09-18 14:31:53    阅读次数:199
【LeetCode】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, given the following triangle [ [2], [...
分类:其他好文   时间:2014-09-18 11:29:23    阅读次数:201
Remove Duplicates from Sorted List II
Given a sorted linked list, delete all nodes that have duplicate numbers, leaving only distinct numbers from the original list.For example,Given 1->2-...
分类:其他好文   时间:2014-09-18 05:24:13    阅读次数:195
<<Python基础教程>>学习笔记 | 第04章 | 字典
第04章:字典 当索引不好用时 Python唯一的内建的映射类型,无序,但都存储在一个特定的键中,键可以使字符,数字,或者是元祖. ------ 字典使用: 表征游戏棋盘的状态,每个键都是由坐标值组成的元祖 存储文件修改的次数,文件名作为键 数字电话/地址薄 函数传递值def func(x,*args,**args): 如果要建公司员工与座机号的列表,如果要获得Alice的座机只能这么找 >>> names = ['Alice','Bob','Tom'] >>> numbers = ['1234','7...
分类:编程语言   时间:2014-09-17 23:26:13    阅读次数:589
Valid Palindrome
[leetcode]Given a string, determine if it is a palindrome, considering only alphanumeric characters and ignoring cases....
分类:其他好文   时间:2014-09-17 23:24:22    阅读次数:198
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!