码迷,mamicode.com
首页 >  
搜索关键字:numbers range    ( 16974个结果
【从0开始Tornado建站】群聊
群聊的前台主要代码: {%block content%} 测试版本,每天凌晨4:00清水,enjoy it~~:-)--> {%for i in content[19*int(num)-19:19*int(num)]%} 【{{i[1]}}】 ({{i[3]}}) : {{i[2]}} {%end%} {%for i in range(1,pages+1)%} {{i}} {%...
分类:其他好文   时间:2014-05-13 23:14:45    阅读次数:388
[leetcode]Sum Root to Leaf Numbers @ Python
原题地址:http://oj.leetcode.com/problems/sum-root-to-leaf-numbers/题意:Given a binary tree containing digits from0-9only, each root-to-leaf path could repre...
分类:编程语言   时间:2014-05-12 01:28:30    阅读次数:440
leetcode --day12 Surrounded Regions & Sum Root to Leaf Numbers & Longest Consecutive Sequence
1、 ?? Surrounded Regions Given a 2D board containing 'X' and 'O', capture all regions surrounded by 'X'. A region is captured by flipping all 'O's into 'X's in that surrounded region. For e...
分类:其他好文   时间:2014-05-11 18:52:32    阅读次数:293
Leetcode | Multiply Strings
Given two numbers represented as strings, return multiplication of the numbers as a string.Note: The numbers can be arbitrarily large and are non-nega...
分类:其他好文   时间:2014-05-11 14:35:13    阅读次数:270
一维数组元素的输入输出方法总结
1、数组的下标法:直观且容易理解如:int a[5],i;printf("Input five numbers:");for(i=0;i<5;i++){scanf("%d",&a[i]);}for(i=0;i<5;i++){ printf("%4d",a[i]);}2、数组名首地址法(指针法):指针...
分类:其他好文   时间:2014-05-11 00:35:46    阅读次数:351
【LeetCode】Integer to Roman
Given an integer, convert it to a roman numeral.Input is guaranteed to be within the range from 1 to 3999.public class Solution { public String int...
分类:其他好文   时间:2014-05-10 20:31:10    阅读次数:335
dmidecode 命令
dmidecode # 查看全面硬件信息dmidecode | grep "Product Name" # 查看服务器型号dmidecode | grep -P -A5 "Memory\s+Device" | grep Size | grep -v Range # 查看内存插槽
分类:其他好文   时间:2014-05-10 08:00:29    阅读次数:540
CSU 1030
1 #include 2 #define range 1300000 3 #define BOOL int //必须把bool,true,false这样表示出来,不然会报编译错误...不知道为什么囧... 4 #define true 1 5 #define false 0 6 BOOL p...
分类:其他好文   时间:2014-05-10 06:56:39    阅读次数:283
Highly divisible triangular number
我的那个暴力求解,太耗时间了。用了网上产的什么因式分解,质因数之类的。确实快!还是数学基础不行,只能知道大约。The sequence of triangle numbers is generated by adding the natural numbers. So the 7th triangl...
分类:其他好文   时间:2014-05-09 23:43:16    阅读次数:342
Large sum
聪明的办法是想:求前10位,那只要前8位加起来,进2位就OK。本的办法,就是真的加起来,截前面10位。如我。numList = str.split()sum = 0for i in range(0,len(numList)): sum += int(numList[i][0:50]) p...
分类:其他好文   时间:2014-05-09 23:16:32    阅读次数:350
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!