码迷,mamicode.com
首页 >  
搜索关键字:return    ( 60766个结果
LeetCode--Reverse Words in a String
Given an input string, reverse the string word by word.For example,Given s = " the sky is blue ",return "blue is sky the".click to show clarification....
分类:其他好文   时间:2014-07-16 20:27:53    阅读次数:134
基本概念: 均值,期望,中位数,众数,极差,总体方差,样本方差,协方差
# --*-- coding:utf-8 --*--import mathimport itertoolsdef Mean(t): """均值""" return float(sum(t)) / len(t)def E(x, p): """ 离散性随即变量的数学期望(也称为均...
分类:其他好文   时间:2014-07-16 20:18:01    阅读次数:220
Java删除文件夹和文件
通用的文件夹或文件删除方法,直接调用此方法,即可实现删除文件夹或文件,包括文件夹下的所有文件Java代码/***根据路径删除指定的目录或文件,无论存在与否*@paramsPath要删除的目录或文件*@return删除成功返回true,否则返回false。*/publicbooleanDeleteFo...
分类:编程语言   时间:2014-07-16 20:07:39    阅读次数:194
JS 函数 检验输入是否为数字类型,正整数
function isPositiveNum(s) { //是否为正整数 var re = /^[0-9]*[1-9][0-9]*$/; return re.test(s) } ...
分类:Web程序   时间:2014-07-16 20:04:26    阅读次数:201
拼图效果
public static Bitmap getComponseBitmap(Bitmap src, Bitmap src2){ if(src == null || src2 == null) return null; int width = src.getWidth(); int h...
分类:其他好文   时间:2014-07-16 19:49:20    阅读次数:167
浏览器的判断;
JS判断是不是IE浏览器(IE6-IE11) function isIE() { //ie? if (!!window.ActiveXObject || "ActiveXObject" in window) return true; else r...
分类:其他好文   时间:2014-07-16 19:43:15    阅读次数:161
Python字节码与解释器学习
参考:http://blog.jobbole.com/55327/http://blog.jobbole.com/56300/http://blog.jobbole.com/56761/1. 在交互式命令行中执行命令的内部过程当你敲下return键的时候,python完成了以下四步:词法分析、句法分...
分类:编程语言   时间:2014-07-13 11:55:50    阅读次数:221
phpcms常用标签
获取某个栏目下的列表: {pc:content action="lists" catid="15" num="10" order="id DESC" return="info"} {loop $info $v} {$v['title']}{date('m-d',$v['inputt...
分类:Web程序   时间:2014-07-13 10:45:13    阅读次数:253
LeetCode——Pascal's Triangle II
Given an index k, return the kth row of the Pascal's triangle. For example, given k = 3, Return [1,3,3,1]. Note: Could you optimize your algorithm to use only O(k) extra space? 原题链接:https:/...
分类:其他好文   时间:2014-07-12 20:43:11    阅读次数:213
poj 2236 Wireless Network 并查集
#include #include #include #define maxn 1220double x[maxn],y[maxn],d;bool vis[maxn];int p[maxn];int n;double dist(int i,int j){ return fabs( (x[i]-...
分类:Web程序   时间:2014-07-12 14:36:39    阅读次数:224
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!