一道面试题,以下程序的输出是?public class StaticDispatch { static abstract class Human{ } static class Man extends Human{ } static class Woman extends Human{ } publ...
分类:
编程语言 时间:
2014-07-16 21:48:37
阅读次数:
229
6.线上查询的命令:(1)man命令:用来查询和解释一个命令的使用方法以及这个命令的说明事项。[man 命令的名称](2)locate命令:定位文件和目录。(3)whatis命令:用来查询某个命令的含义[whatis 命令的名称]:比较适用7.文件阅读的命令:(1)head命令:用来查看文件的开头部...
分类:
系统相关 时间:
2014-07-16 17:56:17
阅读次数:
233
[root@localhost ~]# which passwd/usr/bin/passwd[root@localhost ~]# whereis passwdpasswd: /usr/bin/passwd /etc/passwd /usr/share/man/man1/passwd.1.gz /...
分类:
系统相关 时间:
2014-07-13 17:55:28
阅读次数:
352
Red and BlackProblem DescriptionThere is a rectangular room, covered with square tiles. Each tile is colored either red or black. A man is standing on...
分类:
其他好文 时间:
2014-07-13 13:10:07
阅读次数:
220
通过修改/etc/inittab.通过这个文件修改系统的启动方式.
ls –l /etc/ | more (管道),将前面的结果交给后面的命令进行处理。
在linux中遇到问题使用man命令。
查找文件信息并将文件存储到一个制定的文件中。
ls –la > “a.txt”
创建组名:
创建组:
查...
分类:
系统相关 时间:
2014-07-12 20:36:34
阅读次数:
419
Given a string, determine if it is a palindrome, considering only alphanumeric characters and ignoring cases.
For example,
"A man, a plan, a canal: Panama" is a palindrome.
"race a car" is not a ...
分类:
其他好文 时间:
2014-07-12 20:10:54
阅读次数:
165
LINUX环境下多线程编程肯定会遇到需要条件变量的情况,此时必然要使用pthread_cond_wait()函数。但这个函数的执行过程比较难于理解。
pthread_cond_wait()的工作流程如下(以MAN中的EXAMPLE为例):
Consider two shared variables x and y, protected by the mutex mut,...
分类:
其他好文 时间:
2014-07-10 19:50:36
阅读次数:
347
终极解决方案:赋予svn文件root权限1. 查找svn文件:1 $ whereis svn2 svn: /usr/bin/svn /usr/bin/X11/svn /usr/share/man/man1/svn.1.gz3 $ 2. 查看当前权限:$ ls -l /usr/bin/svn-rwxr...
分类:
其他好文 时间:
2014-07-09 17:05:39
阅读次数:
196
当我们需要 bash 执行命令后的数据进行加工时就可以用到了界定符号: |注:管道命令接仅会接收正确数据选取命令: cut 切割 -d 以什么分割成域 -f 获取指定的域和不包含分隔符的行 num或者 num,num -c 获取某列的值num / num- eg: man cut | cut ...
分类:
其他好文 时间:
2014-07-09 14:31:05
阅读次数:
202
一道面试题,下面程序的输出是?
public class StaticDispatch {
static abstract class Human{
}
static class Man extends Human{
}
static class Woman extends Human{
}
public void sayHello(Human guy){
System.out...
分类:
编程语言 时间:
2014-07-09 12:06:54
阅读次数:
213