Given a positive integer, return its corresponding column title as appear in an Excel sheet. For example: ...
分类:
其他好文 时间:
2016-04-14 01:28:28
阅读次数:
176
// **Day9 // CloseSure var arr:[Int] = [1,2,3,4,5,9,8,7,6,0] arr.sort() func compareTwoInts(a:Int,b:Int) -> Bool { return a>b } arr.sort(compareTwoInt ...
分类:
其他好文 时间:
2016-04-14 01:18:50
阅读次数:
174
今天去逛论坛 时发现了一个很有趣的问题: 谁能给我我解释一下这段程序的结果为什么是:2.而不是:3 代码如下: 看了问题后,得出了以下几个问题: 如果在 try 语句块里使用 return 语句,那么 finally 语句块还会执行吗?(果你的答案是不会执行,请务必要看下去 ^_^) 如果执行,那么 ...
分类:
其他好文 时间:
2016-04-13 22:21:30
阅读次数:
273
/*
*比较过程思路:
*1、两个对象指向位置相同,那么他们就相等,return后跳出函数,不再往下执行
*2、指向位置不同,有3情况
*a:这两对象类型相同,并且内容相同,也属于相等
*b:类型相同,内容不同,属于不等;
*c:类型不同,属于不等
*/
classObjectEquals{
publicstatic..
分类:
编程语言 时间:
2016-04-13 21:10:19
阅读次数:
233
题目: Given an integer array nums, return the number of range sums that lie in [lower, upper] inclusive. Range sum S(i, j) is defined as the sum of the ...
分类:
其他好文 时间:
2016-04-13 20:37:48
阅读次数:
138
1.事件冒泡机制: 事件冒泡机制也就是当一个事件绑定到一个元素上时,如果这个元素不存在或者回调函数返回ture,那么这个事件就会向上冒泡,继续绑定这个元素的父级元素直至document。(如果事件返回return false则不会冒泡) 阻止冒泡:1.事件return false ; 2.evt.s ...
分类:
其他好文 时间:
2016-04-13 20:27:11
阅读次数:
165
指令难点在于参数 angular.module('app', []) .directive('myDirective', function() { return { restrict: String, priority: Number, terminal: Boolean, template: St ...
分类:
Web程序 时间:
2016-04-13 20:13:23
阅读次数:
253
关于表单的验证有三种: 1、yii的客户端验证 2、yii的服务器端验证 3、yii的ajax验证 例如: 1、在表单对应的模型中定义一个rules方法(该方添加后,在表单提交时,将自动被调用) public function rules() { return array( array("表单元素名... ...
分类:
其他好文 时间:
2016-04-13 18:59:07
阅读次数:
168
import xlrd def open_excel(fileName="TransInfo.xlsx"): try: fileHandler = xlrd.open_workbook(fileName) return fileHandler except Exception as e: print ...
分类:
编程语言 时间:
2016-04-13 14:39:16
阅读次数:
172
Given a linked list, remove the nth node from the end of list and return its head. For example, Note:Given n will always be valid.Try to do this in on ...
分类:
其他好文 时间:
2016-04-13 13:07:11
阅读次数:
159