/** * 判断集合是否为空 * * @param list * 集合 */ public static boolean isEmpty(List list) { if (list != null && list.size() > 0) { return false; } else { return ...
分类:
其他好文 时间:
2016-09-21 11:33:09
阅读次数:
107
Given a string, find the first non-repeating character in it and return it's index. If it doesn't exist, return -1. Examples: Note: You may assume the ...
分类:
其他好文 时间:
2016-09-21 06:46:53
阅读次数:
118
Given an arbitrary ransom note string and another string containing letters from all the magazines, write a function that will return true if the rans ...
分类:
其他好文 时间:
2016-09-21 01:47:19
阅读次数:
186
functionfactorial($x)
{
if($x>1){
$s=$x*factorial($x-1);
}else{
$s=$x;
}
return$s;
}
$x=100;
echo$x."的阶乘的为".factorial($x);
分类:
Web程序 时间:
2016-09-21 00:13:04
阅读次数:
334
Calculate the sum of two integers a and b, but you are not allowed to use the operator + and -. Example:Given a = 1 and b = 2, return 3. 题目要求:计算两个整型的和 ...
分类:
其他好文 时间:
2016-09-21 00:07:10
阅读次数:
105
Write a function that takes a string as input and reverse only the vowels of a string. Example 1:Given s = "hello", return "holle". Example 2:Given s ...
分类:
其他好文 时间:
2016-09-20 23:56:48
阅读次数:
142
Given two arrays, write a function to compute their intersection. Example:Given nums1 = [1, 2, 2, 1], nums2 = [2, 2], return [2]. Note: Each element i ...
分类:
其他好文 时间:
2016-09-20 23:52:22
阅读次数:
143
Given two arrays, write a function to compute their intersection. Example:Given nums1 = [1, 2, 2, 1], nums2 = [2, 2], return [2, 2]. Note: Each elemen ...
分类:
其他好文 时间:
2016-09-20 23:49:46
阅读次数:
135
Given an integer (signed 32 bits), write a function to check whether it is a power of 4. Example:Given num = 16, return true. Given num = 5, return fa ...
分类:
其他好文 时间:
2016-09-20 22:28:24
阅读次数:
190
--函数 functioncreate or replace function fn_teacher_tid(f_tid char --用户传递的参数)return char --返回值的类型is --声明返回值f_result teacher.tid%type;begin if length(f_ ...
分类:
数据库 时间:
2016-09-20 21:25:39
阅读次数:
165