本例实现问答的板块。相关sql:1.questions: {id, asker, title, content, keyword, time};2.answers : {id, answer, question_id, content, time};问题前台:question.php 1 ...
分类:
其他好文 时间:
2014-07-22 22:36:15
阅读次数:
274
进到8088页面后,怎么看不到mapreudce的执行状态,有哪里需要配置的解决办法:在$HADOOP_HOME/conf/mapred-site.xml 在原来的配置文件基础之上添加: mapreduce.framework.name yarn mapre...
分类:
其他好文 时间:
2014-07-22 22:36:15
阅读次数:
211
利用javascript进行数组去重,调研了下面几种方法:1.遍历数组,删除已出现的元素var uniqueArrByDel = function(arr){ for(var i = 0; i < arr.length-1; i++){ var item = arr[i]; f...
分类:
其他好文 时间:
2014-07-22 22:36:16
阅读次数:
217
# Copyright 2006 Joe Wreschnig## This program is free software; you can redistribute it and/or modify# it under the terms of the GNU General Public Li...
分类:
其他好文 时间:
2014-07-22 22:36:33
阅读次数:
351
CommandDescriptionExampleget读取键值get mykeyset设置新键值set mykey 0 60 5add新增键值add newkey 0 60 5replace替换现有值replace key 0 60 5append末尾添加值append key 0 60 15pr...
分类:
其他好文 时间:
2014-07-22 22:36:33
阅读次数:
212
近期看了一下JVM对监控的支持,除了常规的JMX外居然还有SNMP, 有点意思, 这个网管协议适配的地方还真多,那么就先测试一下。先随便找一个能在后台持续运行的java小程序,如我手头的BIO的socket服务器。JVM端SNMP的配置启动SNMP需要两个地方更改,(http://docs.orac...
分类:
其他好文 时间:
2014-07-22 22:36:33
阅读次数:
318
一 Words1 draw in 渐短,渐早 e.g. The days draw in and the mornings get darker.天黑得越来越早,天亮得越来越晚。 被卷入,使参与 e.g. You gradually fall under the spell 咒语and get dr...
分类:
其他好文 时间:
2014-07-22 22:36:34
阅读次数:
203
时间格式化CodeDateTime dt = DateTime.Now;Label11.Text = dt.ToString();2005-11-5 13:21:25Label12.Text = dt.ToFileTime().ToString();127756416859912816Label13...
分类:
其他好文 时间:
2014-07-22 22:36:34
阅读次数:
300
Failed to load libGL.soerror libGL.so: cannot open shared object file: No such file or directory启动emulator的时候有如上错误,解决方案:64-bit Ubuntu 12.04.$ sudo apt...
分类:
其他好文 时间:
2014-07-22 22:36:35
阅读次数:
223
Mac OS X 程序员利器 – Homebrew安装与使用Homebrew安装与使用什么是Homebrew?Homebrew is the easiest and most flexible way to install the UNIX tools Apple didn’t include wi...
分类:
其他好文 时间:
2014-07-22 22:36:36
阅读次数:
217
#-*-coding:utf-8-*-fromctypesimport*importtimeclassMEMORYSTATUS(Structure):while1:_fields_=[('dwLength',c_int),('dwMemoryLoad',c_int),('dwTotalPhys',c...
分类:
其他好文 时间:
2014-07-22 22:36:36
阅读次数:
219
#VorbiscommentsupportforMutagen#Copyright2005-2006JoeWreschnig##Thisprogramisfreesoftware;youcanredistributeitand/ormodify#itunderthetermsofversion2of...
分类:
其他好文 时间:
2014-07-22 22:36:37
阅读次数:
265
1、布局 先创建一个非响应的布局,页面宽度固定大小。然后添加媒体查询(Media Queries)和响应式代码。这种操作方式更容易实现响应式特性,在同一时间专注于一个任务。 然后做如下设置(屏幕按1:1的尺寸显示,在 iPhone 和其他智能手机的浏览器提供网站全视图浏览,并禁止用户缩放页面。)2 ...
分类:
其他好文 时间:
2014-07-22 22:36:53
阅读次数:
170
Problem DPiotr's AntsTime Limit: 2 seconds"One thing is for certain: there is no stopping them;the ants will soon be here. And I, for one, welcome ou....
分类:
其他好文 时间:
2014-07-22 22:36:53
阅读次数:
363
由于Tomcat在默认情况下会将没有经过配置的web应用所产生的日志输出已及其本身的日志内容都输出到这个文件中,那么随着时间的推移,这个文件的尺寸将会越来越大,当需要检查日志内容时间会导致文件难以打开,而且同时tomcat依旧在不断的向文件中输入内容,这也会降低tomcat的性能。下面利用一个工具来...
分类:
其他好文 时间:
2014-07-22 22:36:53
阅读次数:
200
CombinationsGiven two integersnandk, return all possible combinations ofknumbers out of 1 ...n.For example,Ifn= 4 andk= 2, a solution is:[ [2,4], [3.....
分类:
其他好文 时间:
2014-07-22 22:36:54
阅读次数:
153
dp[x][y]:如今有x个白老鼠,y个黑老鼠,公主赢的概率。那么:假设公主直接拿到白老鼠,概率为x/(x+y),公主赢。假设公主拿到黑老鼠,概率为y/(x+y),那么公主假设想赢,龙必须拿到黑老鼠,概率为(y-1)/(x+y-1);那么逃跑的老鼠为黑老鼠的概率为(y-2)/(x+y-2),为白老鼠...
分类:
其他好文 时间:
2014-07-22 22:36:54
阅读次数:
205