一、创建函数函数是一种对象:Function类 是对象,可以通过Function 实例化一个函数,不过最多的还是利用function 来创建函数。方式一:利用Function类 来实例化函数:1 var people=new Function("name","sex","if (sex=='男') ...
分类:
编程语言 时间:
2014-10-25 14:21:17
阅读次数:
204
I've heard several people asking why GCHandle doesn't implement IDisposable, considering it wraps an unmanaged resource (a handle) and needs to be exp...
分类:
其他好文 时间:
2014-10-25 13:11:03
阅读次数:
298
people = 20cats = 30dogs = 15if people cats: print "Not many cats! The world is saved!"if people dogs: print "The world is dry!"dogs += 5if people...
分类:
其他好文 时间:
2014-10-24 18:01:42
阅读次数:
159
Some people think that the bigger an elephant is, the smarter it is. To disprove this, you want to take the data on a collection of elephants and put as large a subset of this data as possible into a...
分类:
其他好文 时间:
2014-10-23 20:51:42
阅读次数:
221
Coprime
Time Limit: 2000/1000 MS (Java/Others) Memory Limit: 262144/262144 K (Java/Others)
Total Submission(s): 130 Accepted Submission(s): 59
Problem Description
There are n people ...
分类:
其他好文 时间:
2014-10-23 17:46:16
阅读次数:
209
x = "There are %d types of people." % 10binary = "binary"do_not = "don't"y = "Those who know %s and those who %s." % (binary, do_not)print xprint ypri...
分类:
其他好文 时间:
2014-10-22 14:22:51
阅读次数:
122
// Playground - noun: a place where people can play
import UIKit
//------------------------------------------------------------------------------
// 1. 基本使用
// switch 与OC的区别:
// 1> 不需要写break
// 2> 每...
分类:
编程语言 时间:
2014-10-21 15:26:06
阅读次数:
220
{"people": ["city","name"]} // []中不能含有 key:value的形式{"name": "laogao","city": "beijing"} //{}通常含有key:value对["name","city"] //[]通常含有value的列表,多个用,隔开
分类:
Web程序 时间:
2014-10-21 00:35:32
阅读次数:
288
// Playground - noun: a place where people can play
import UIKit
//------------------------------------------------------------------------------
// 1. for
// 传统的for循环方式在swift中同样支持
var num = 0
for(v...
分类:
编程语言 时间:
2014-10-20 15:14:51
阅读次数:
221
坦克大战
时间限制:1000 ms | 内存限制:65535 KB
难度:3
描述
Many of us had played the game "Battle city" in our childhood, and some people (like me) even often
play it on computer now.
What we a...
分类:
其他好文 时间:
2014-10-19 11:40:56
阅读次数:
309