码迷,mamicode.com
首页 >  
搜索关键字:python function    ( 188437个结果)
白手起家搭建django app
$django-admin.py startproject web2$cd web2/$python manage.py startapp blog$vim web2/settings.py 注意settings.py以下两个部分,首先要配置数据库,其次要在INSTALLED_APP里添加刚才新建的...
分类:移动开发   时间:2014-06-08 22:18:14    阅读次数:377
js中call、apply、bind的用法
今天看博客时,看到了这样的一段js代码:var bind = Function.prototype.call.bind(Function.prototype.bind);我想突然看到这样的一段代码,即使js能力再强的人,可能也需要花点时间去理解。像我这样的菜鸟就更不用说了。其实,原文已经对这端代码做...
分类:移动开发   时间:2014-06-08 22:10:19    阅读次数:335
HNOI2008玩具装箱 (斜率优化)
总算A了,心情好激动……如果会了一类斜率优化,基本上这类题就成了套模版了……只是k函数不同 1 var n,l,x,tail,head,m:int64; 2 i,j:longint; 3 dp,q,s:array[0..100000] of int64; 4 function k(x...
分类:其他好文   时间:2014-06-08 21:53:27    阅读次数:247
03微信公众平台 - 实现【天气查询】功能函数,返回一个文本字符串。
一、功能代码函数实现 private function _weather($city) { include("weather_cityId.php"); $c_name=$weather_cityId[$city]; if(!em...
分类:微信   时间:2014-06-08 21:05:51    阅读次数:1484
[leetcode]Sqrt(x) @ Python
原题地址:https://oj.leetcode.com/problems/sqrtx/题意:Implementint sqrt(int x).Compute and return the square root ofx.解题思路:实现开平方函数。这里要注意的一点是返回的时一个整数。通过这一点我们可...
分类:编程语言   时间:2014-06-08 21:04:38    阅读次数:329
[leetcode]Search for a Range @ Python
原题地址:https://oj.leetcode.com/problems/search-for-a-range/题意:Given a sorted array of integers, find the starting and ending position of a given target ...
分类:编程语言   时间:2014-06-08 21:03:21    阅读次数:297
05微信公众平台 - 实现【点歌】功能函数,返回一个文本字符串。
一、功能代码函数实现 /* * 功能5:根据歌名点歌功能,输入歌名即可,传入参数为输入对象$postObj */ private function _listenMusic($postObj) { $ret= " ...
分类:微信   时间:2014-06-08 20:59:11    阅读次数:684
[leetcode]Sort Colors @ Python
原题地址:https://oj.leetcode.com/problems/sort-colors/题意:Given an array withnobjects colored red, white or blue, sort them so that objects of the same col...
分类:编程语言   时间:2014-06-08 20:56:32    阅读次数:394
04微信公众平台 - 实现【翻译】功能函数,返回一个文本字符串。
一、功能代码函数实现 private function _baiduDic($keyword) { $tranurlaip = "http://openapi.baidu.com/public/2.0/bmt/translate?client_id=9peNkh97N6B...
分类:微信   时间:2014-06-08 18:39:59    阅读次数:560
HNOI2004打鼹鼠(LIS)
大水题……不过通过这题我们应该养成一个好习惯:好好看清题……竟然没有看到时限 10sec…… 1 var i,j,n,m,ans:longint; 2 f,time,x,y:array[0..15000] of longint; 3 function max(x,y:longint):lon...
分类:其他好文   时间:2014-06-08 18:38:49    阅读次数:261
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!