题目:Given an input string, reverse the string word by word.For example,Given s = "the sky is blue",return "blue is sky the".要求:1)首尾有空格的时候,反转后的string要将空...
分类:
其他好文 时间:
2014-07-16 19:29:54
阅读次数:
234
题目:Given an input string, reverse the string word by word.For example,Given s = "the sky is blue",return "blue is sky the". 1 public String reverseWor...
分类:
其他好文 时间:
2014-07-14 09:06:02
阅读次数:
176
1.从外围搜索O,深度搜索出现了Line 35: java.lang.StackOverflowErrorLast executed input:["OOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOO 1 public class Solution { 2...
分类:
其他好文 时间:
2014-07-13 22:12:53
阅读次数:
254
配置nginx支持php 出现了No input file specified ?
只要修改下安装目录下的 nginx.conf下的
location ~ \.php$ {
root html;
fastcgi_pass 127.0.0.1:9000;
fastcgi_index ...
分类:
Web程序 时间:
2014-07-13 16:16:48
阅读次数:
270
Given a string containing just the characters '(', ')', '{', '}', '[' and ']',
determine if the input string is valid.
The brackets must close in the correct order, "()" and "()[]{}" are
all va...
分类:
其他好文 时间:
2014-07-13 16:11:26
阅读次数:
144
Description
有形如:ax3+bx2+cx+d=0 这样的一个一元三次方程。给出该方程中各项的系数(a,b,c,d 均为实数),并约定该方程存在三个不同实根(根的范围在-100至100之间),且根与根之差的绝对值>=1。请你求出这个方程的三个实根。
Input
只有一行,包括4个实数a,b,c,d,中间用一个或多个空格隔开。
Output
只...
分类:
其他好文 时间:
2014-07-13 15:31:03
阅读次数:
238
3种事件模型:原始事件模型DOM事件模型IE事件模型原始事件模型(0级事件模型)1、事件处理程序被定义为函数实例,然后绑定到DOM元素事件对象上,实现事件的注册。例子:varbtn=document.getElementsByTagName("input")[0];btn.onclick=function(){函数体....}2、也可以把特定的..
分类:
Web程序 时间:
2014-07-13 15:04:39
阅读次数:
208
Description
鸡腿具有无穷魅力,每个经历军训的人都对他有特别的感情。当无数鸡腿摆在我们面前时,我们该何去何从。
现在嘴馋的KG就面临着这种问题。现在他的面前有M个鸡腿,N个盘子。他要将这些鸡腿放在这N个盘子中。他一共有多少种不同分法。(如5,2和2,5是相同分法)
Input
第一行是测试数据的数目t(0
Output
对输入的每组数据M和N...
分类:
其他好文 时间:
2014-07-13 13:46:04
阅读次数:
198
/*
G - 寻找大富翁
Time Limit:1000MS Memory Limit:32768KB 64bit IO Format:%I64d & %I64u
Submit
Status
Description
浙江桐乡乌镇共有n个人,请找出该镇上的前m个大富翁.
Input
输入包含多组测试用例.
每个用例首先包含2个整数n(0<n<=100000)和m(0<m<=10)...
分类:
其他好文 时间:
2014-07-12 21:31:59
阅读次数:
232
Description
现在给你一个字典,再给出几个字符串,让你查找,这些字符串是否在其中。
Input
第一行是两个整数M,N分别表示字典数和字符串数。
第2至第M+1行,每一行是一个字典。
第M+2至第M+2+N行是徐查找的字符串。
(n
Output
共N行,每行表示第i个字符串在不在字典中,用0表示不在,1表示在。
Sample Inpu...
分类:
其他好文 时间:
2014-07-12 18:41:16
阅读次数:
236