Skip to content →

Category: Blog

Privilege given up

I’ve given up the privilege to enter graduate school without examinations. Yeah, to many of my fellow students I’m a little too bald. After all, I may get into a top graduate school in China.

Then what? I would get a master’s degree and then apply abroad grad schools? It’s true that if I choose to stay home, now I shall be rather relaxed instead of worrying about how many scores I may get in the GRE and TOEFL, or what should be added into my PS and resume, or, what’s the possibility that I can get into a top group. But if I am easy now, two or three years later I may well go through all the difficulties and barriers that I’m faced with today. So why not fight today for a better tomorrow?

Besides, I do not see any grad school in China interests me. From my point of view, there’s little difference between undergraduate and graduate education in China. A lot of postgraduates crowd in the lab and doing what they do not want to do, with little, if any, help or directions from their supervisors. That’s not what I want to do for the next two or three years.

I believe action makes differences. Still I believe my efforts will pay off.

Life is mysterious; future is unknown; I shall just go.

 

2 Comments

Traveling

Traveling is one of the best ways to learn. You can experience what you have not experienced before. You can visit majestic buildings. You can taste marvelous foods. You can make friends with all kinds of people. You can learn the people, the language, the culture, and the history. Thanks to the diversity and magnificence of the world, by traveling you can broaden your horizons and open your eyes to the world.

Traveling is good for your health, too. From one aspect, it is refreshing. With all kinds of magnificent scenery, you will just forget the trifles and pressure in your mind. From another, you will exercise a lot when you are on the go. For example, when you climb the mountains, you are just doing sports. So if you want to keep fit, just go and travel!

But traveling is for the brave ones, for to travel means to explore. You have no idea with what is going to happen and what you are going to see and feel. There are always surprises. You are likely to see the scenery you have not expected. Sometimes it is quite magnificent. But on other occasions it could be rather unattractive, which you have to bear with all your efforts.

Anyway, traveling is becoming more and more popular. It benefits us a lot. So why not?

 

Leave a Comment

The Bucket List

Today I saw the movie The Bucket List directed by Rob Reiner, in which Jack Nicholson and Morgan Freeman acted as two patients who had been diagnosed with cancer. Knowing their approximate day of dying, they wrote their “bucket list” – the wishes they wanted to realize before kicking the bucket but had not yet been carried out. The list reads:

1. Help a complete stranger for the good.

2. Laugh until I cry.

3. Witness something that is majestic.

4. Sky diving.

5. Kiss the most beautiful girl in the world.

6. Get a tattoo.

7. Drive a Shelby.

Etc.

They went and gave it a shot. They realized most of the wishes on the list.

Then I begin to think, what if I were told to be dying in a couple of months? What will be my bucket list? That is a really tough question. It is said in the movie that 96 percent of people do not want to know their day of dying. But it is a realistic question that everyone may be faced with. So here goes my “bucket list”:

1. Find the most innocent kid in the world and look deep into his eyes.

2. Apologize with all my heart and soul to whom I have ever broken their hearts.

3. Spent a whole day alone, thinking about my whole life.

4. Talk with my family. Tell my childhood memories to my children.

5. Go to the forest and appreciate every creature with gratefulness.

6. Find a place extremely quiet and listen to the sound of silence.

People always talk about what are really important in life. But they seldom pursue them. Everyday we are concerning about how much money we are making, how large out house could be. However, we care little about love for another and our health.

May be it is high time that we settled out finding the essence of life.

 

Leave a Comment

Think before you speak

It cost me ¥1 to learn this proverb. I should have learned it before, but I hope it’s the last time I pay the tuition.

Rocky is the foreign teacher today in the English corner, and he is surely a shrewd one. “I can do two to three hundred push-ups in four minutes. You give me one Yuan and if I lose, I’ll return you two Yuan.” Considering his size, I said “I’m in!” and gave him one Yuan. He is 180 kilograms, how could he do 200 push-ups in 4 minutes? There it goes. He did three push-ups and then stand up, looking at us seriously, “You lose.” “Why?”

“I’ve told you to think before you speak, I just said I could do 2 to 300 push-ups in four minutes, so I win!”

“……”

“So these are mine!” Holding a handful of one-Yuan notes, he said happily. For some other guys also joined the game, one of them even bet two Yuan for it.

Well, there my money goes, but besides, I’ve learnt something more, such as “adidas” means “All Day I Dream About Sex”.

But I should have been more careful. I thought I was a boy of principle. I never gamble and I hate it. But today I couldn’t help betting with Rocky, why? Why I’m always lured by some minor benefit? I could never be too careful.

 

Leave a Comment

帮硕哥装Linux杂记

今天帮硕哥装了GNU/Debian Linux,没有安装盘,所以还是像以前一样通过网络安装,最开始装WinGrub是不能将Grub装到MBR上,捣鼓了一阵子之后还是不知道怎么回事,后来重启无意发现他的机器装了矮人工具箱,它是利用Grub引导的,于是就直接进命令行,输入启动参数,启动,开始下载安装。但是不知道是校园网慢还是硕哥的网络慢,装了一个多小时才装好。装好基本系统后又帮他配置了Java,还下了LumaQQ。然后进Windows,将剩余的硬盘分区重新划给Windows,大功告成,上楼看书。

不一会儿,硕哥又来找我了,说进不去系统了。我下去一看,Grub error 17,凭我装系统的经验(汗一个,为自己的硬盘默哀一秒钟)判断,应该是分区表损坏,于是,拿上Hiweed光盘,进系统,准备重装Grub:

grub>root (hd0, 5)

提示不能找到此分区,faint,退出Grub,运行 sudo fdisk -l ,不有这个分区吗?Grub凭什么找不到?

正百思不得其解的时候,恍然大悟,是不是权限问题?

重新运行grub,不过用的是超级用户权限, sudo grub:

grub>root (hd0,5)

grub>setup (hd0)

OK,大功告成!

再更改fstab,Grub的menu list,搞定。

以前自以为自己用了一年半的Linux了,Linux的安全思想已经深入我心,今天看来其实不然,连最基本的系统权限控制都没有深入理解,以后加油。

另外有感于自己帮助装了Linux操作系统的同学,自己帮很多人装了Linux,但真正使用的还是只有我一个。虽然我不是激进的开源或自由软件信徒,但是在Windows大行其道的情况下,Linux在桌面级应用超过M$可能真的需要很长一段时间。

 

Leave a Comment

VIM C++ (全能)自动补全: OmniCppComplete

下载:http://vim.sourceforge.net/scripts/script.php?script_id=1520

1.把下载的 omnicppcomplete.zip 解压到 ~/.vim 中

2.建立 tags:
[email protected]:/home/rok# cd /usr/local/share/
[email protected]:/usr/local/share# mkdir tags
[email protected]:/usr/local/share# cd tags/
[email protected]:/usr/local/share/tags# ctags -R –c++-kinds=+p –fields=+iaS –extra=+q /usr/include/c++/4.1.2/

3.在 .vimrc 中添加:
set nocp
filetype plugin on
filetype indent on
set tags+=/usr/local/share/tags/tags
au BufWritePost *.c,*.cpp,*.cc,*.h !ctags -R –c++-kinds=+p –fields=+iaS –extra=+q .

Leave a Comment

终于搞定 Slackware 12.0 挂载的乱码问题了

只需要改一下fstab就可以了:

/dev/hda2 swap swap defaults 0 0
/dev/hda1 / ext3 defaults 1 1
/dev/hda5 /home ext3 defaults 1 0
/dev/hda3 /win vfat defaults,codepage=936,iocharset=utf8,umask=000 1 0
/dev/sda1 /mnt/usb1 auto
noauto,codepage=936,iocharset=utf8,user,umask=000 0 0
/dev/sda /mnt/usb auto noauto,codepage=936,iocharset=utf8,user,umask=000 0 0
#/dev/cdrom /mnt/cdrom auto noauto,owner,ro 0 0
#/dev/fd0 /mnt/floppy auto noauto,owner 0 0
devpts /dev/pts devpts gid=5,mode=620 0 0
proc /proc proc defaults 0 0

 

Leave a Comment

Mother’s Day: What I have done and What I should have done for my Mother

It’s Mother’s Day today. I’ve never celebrated Mother’s Day anyway. But, I think it’s time to express my gratitude and my deep feelings; and we shall always learn to express our feelings, gratitude, regret, etc.

I’m not going to ‘celebrate’ Mother’s Day though; instead, I don’t think Mother’s Day should only be celebrated on this particular day. In fact, I do think that everyday may be the same; and we should ‘celebrate’ Mother’s Day EVERYDAY!

Well, my mother has nothing in particular indeed; she is much like every the other mother in the world. She gave me my life; she taught me to walk, to speak, and to be a man with responsibility; she has been loving her son ever since I was born.

Then what I have done?

Well, if I think hard, I do realize something I’ve done sometimes. I have been getting along very well thanks to my family; I have been working very hard towards my destination; and above all, I’ve been living, safe and sound.

But I did make make mistakes. Some of them even made my mother rather sad at times. There was a time when I don’t want live in this world any more owing to the heavy stress of school work. This dangerous and ridiculous idea really scared my mother. She got heartbroken and extremely angry. Fortunately I realized my fault and, very fortunately again, I did very well in the Senior Middle School Entrance Examination.

And what I should have?

Actually I having been thinking about questions like this every single day. And I believe that as long as I’m living soundly, my mother should be quite happy. So, keep in good health and work hard to realize my dreams, that’s all I should have done; and that’s what I have done.

So, on this particular day, I have a clear conscience. And I believe it will be the same for me as well tomorrow and the day after tomorrow.

 

Leave a Comment

一些零碎的记忆・揪耳朵

每每想起这件事,都不由得对父亲肃然起敬。

那是我四岁那年夏天的一个晚上,窗外知了“吱吱”叫个不停,屋内空气凝滞,昏黄的日光灯让小小的房间变成了橙色的蒸笼。我趴在桌子上,手无力的握着铅笔,挣扎着抬起似千斤的眼皮,脸上的汗珠一粒一粒的往下坠。父亲在旁边一边扇着扇子,一边用他那威严的眼睛盯着我:“快写!”

“快写完了来睡觉,远远!”妈妈也躺在床上一边用力的扇着扇子,一边朝我喊到。我已经写完了“李”和“道”,只剩下这最后一个“远”字了,但我终究没有坚持到底的毅力,把铅笔扔到一边:“我不写了!”父亲可不同意,眼神依旧威严,由不得我讨教还价。可我确实已经感觉到了周公对我的呼唤,于是“哇哇”的哭了起来──这似乎不是襁褓之中婴儿的专利。这下父亲可怒了,还没站起来手已经先揪住了我的耳朵。但是可能是我的耳朵上汗太多(也有小孩子的皮肤太细滑的可能),每次父亲想揪着我的耳朵把我从座位上提起来时,每次都以失败告终,父亲这时似乎已经丧失了理智,他一把拽过旁边的毛巾,保住我的耳朵,硬是把我给提了起来。

“耳朵梗子”再“硬”恐怕也难以承受一个人身体的重量,等父亲松开手时,血已经流到了脖子上。剩下的事情我记不太清楚了(当然,我没有昏倒,只是耳朵那里裂开了,问题似乎没想象的那么严重),后来从母亲和其他一些亲戚口中了解到,我有好长时间没和父亲说话──母亲也是。

几年之后,我依然淘气,整天在家翻箱倒柜,一次偶然的机会,我翻到了父亲的帐目本。翻到中间部分,突然发现了一篇“忏悔书”,我细细将它看完,原来父亲那次揪我的耳朵之后后悔万分,便写下了忏悔书。又过了几年,姑妈在也我家看到了父亲的忏悔书,于是,她将它撕了下来,对我说:“等你考上大学之后我再把这个给你!”

后来我考上了大学,成了家族唯一的大学生,但姑妈并没有把父亲的“忏悔书”给我──我依然记得其中的字字句句,而且该忏悔的不是父亲,而是我。

我被揪了耳朵之后,父亲并没有因此而放下他的威严,我不听话的时候他仍然会打我,只是他再也没有揪过我的耳朵,而是打屁股──但从来没有打得皮开肉绽。-:)

现在长大了,偶尔也和父母提及这件事,父亲有时侯会说那次打得还不够狠,以后我不听话了他还会揪我的耳朵;有时也会报怨母亲当时不该催促我快写完了睡觉;有时还会问我有没有留下“后遗症”……不管父亲说什么,我都知道他的心里在想着什么。

但我终究没有“成龙”,也许以后会吧,或者也许真如父亲所说──那次打得还不够狠……

 

Leave a Comment

佛偈

身是菩提树,心如明镜台,时时勤拂拭,勿使惹尘埃。
──经常擦擦眼镜,别让它们沾上灰尘。

菩提本无树,明镜亦非台,本来无一物,何处惹尘埃。
──不戴眼镜,便无所谓尘埃。

黄庭坚自赞偈
似僧有发,似俗无尘,
作梦中梦,见身外身。

来说是非者,
正是是非人。

法本法无法,
无法法亦法。
今付无法时,
法法何曾法。

七佛通戒偈
诸恶莫作,诸善奉行。
自净其意,是诸佛教。

 

Leave a Comment

Experience of Geany — A lightweighted IDE

Geany’s homepage: http://geany.uvena.de/Main/HomePage

Well, since it’s lightweighted, it’s small and, above all, FAST. For personal user, I think it’s much faster than eclipse, and much easier to use than emacs.

It’s basic features:

syntax highlighting
code folding
code completion
auto completion of often used constructs like if, for and while
auto completion of XML and HTML tags
call tips
many supported filetypes like C, Java, PHP, HTML, Python, Perl, Pascal
symbol lists

It’s code completion function is of great help, and will help us a lot!

But there are problems. I’ve used this IDE for only a day, but the auto
indentation function can’t work correctly. For example:

for(i=0;i<10;i++) [press enter here]
[it should be indented like this]
[but not this]

or maybe it’s my problem.

If anyone works this problem out, please email me! Thanks.

 

Leave a Comment

LumaQQ的一点优化

我用的是不带jre版本的LumaQQ,每次启动都狂读硬盘,于是我改了其启动脚本:
PREFIX=
if [ -L “$0” ]; then
PREFIX=readlink -f $0
if [ $? -eq 0 ]; then
PREFIX=dirname $PREFIX
else
PREFIX=file $0
PREFIX=${PREFIX##*symbolic link to }
PREFIX=dirname $PREFIX
fi
else
PREFIX=dirname $0
fi
case $PREFIX in
/*)
;;
*)
cd $PREFIX
PREFIX=pwd
;;
esac
if [ ! -e $HOME/.lumaqq ]; then
mkdir $HOME/.lumaqq
fi
cd $HOME/.lumaqq
ln -sf $PREFIX/log4j.properties $HOME/.lumaqq/log4j.properties
ln -sf $PREFIX/xml
ln -sf $PREFIX/sound
ln -sf $PREFIX/QQWry.dat $HOME/.lumaqq/QQWry.dat
cp=
for i in $PREFIX/lib/*.jar; do
cp=$i:$cp
done
/soft/jdk1.5.0_08/bin/java -Djava.library.path=$PREFIX/swt -classpath $cp
edu.tsinghua.lumaqq.LumaQQ “$HOME/.lumaqq” &
#为了方便,我去掉了原有的注释。
#改动的便是最后一行
#注意:/soft/jdk1.5.0_08/bin/java 为java路径

以上改动如有不妥,还希望大家批评指正,谢谢!

 

Leave a Comment

2006年总结

现在已经是二零零七年,但是过去的一些事情还是值得总结的,现在闲着没事,姑且简单的总结一下吧。

回想过去一年,似乎也没有什么值得得意的事情,从头到尾想一遍:2006年我没有白过,虽然浪费了一些时间,但毕竟人是不能不犯错误的。

二月份到了学校,电脑联网了,当时兴奋得不得了,估计有一个月的时间没认真上课,但有得有失,自己还是从网上学到了一些东西。自己的视野也开拓了许多,正是从那个时候起,自己对自己的专业才有了一个初步的了解,虽然很不全面,很不深入,毕竟是自己的一个很初级的想法。

三月份同样昏昏噩噩,后来听说奶奶走了,自己似乎收敛了一些。但是对于亲人的离去,我却麻木了。也许是自己和奶奶的接触少了,也许是自己长大了,对待死亡没有先前的恐惧了,对于自己的麻木,我也无可奈何,不知道人长大了是不是都会变成这样,唉,还是对自己听之任之吧,毕竟自己还不是那种感情淡漠的人。

四月五月,无话可说,好像参加了学校的ACM选拔赛,名次当然不理想,不过因为自己在JOJ上做的题比较多,最后还是被选进了学校的集训队,这也不是什么很光彩的事,但也不足为耻。

六月,先考了英语四级,后来应该是在准备期末考试,半年没怎么学,考前一个月无论如何也要认真学学。25号考完,他们走后,寝室里就剩下我一个人,可以安静一下了。

七月,本来准备去当家教,没想到初一的知识都忘记了,没办法,还想去餐馆端盘子,终究还是没去。在寝室学习吧,一打开电脑,就在网上找电影,一个暑假,好的坏的电影看了一大堆,到头来什么意思都没有。不过后来看了一点JAVA,学了Photoshop,不过花了好多时间看Photoshop,估计以后用的也会比较少。毕竟自己交一万多的学费不是来学美工的。也好,醒悟得还是比较早。苦海无边,回头是岸啊!

八月,开了学,陪他们去买了电脑,现在每个人都有电脑了,寝室里也疯了。小学期的课也没什么,只有《离散数学》是必修课。这一个学期基本上没怎么上课,先是在寝室学ACM,后来又弄Linux,废寝忘食,终于把Linux装到了电脑上。虽然浪费了自己一点时间,但自己在摸索的过程中也学到了一些东西,比如汉字的编码,字体的显示等等。也好,摸索一下Linux总比天天“优化”Windows好,况且,装上了Linux,不能玩游戏,看电影也不太方便,天天用键盘,不用鼠标,对自己的帮助也是很大的。

九月,新生入学,才想起自己也在大学呆了一年了。唉,光阴似箭啊!去推销《英语周报》,竟然只卖出去三份,如果学弟学妹们都像我当时那么“聪明”,那我能赚多少钱啊!过了几天,竟然发现自己《离散数学》只得了32分!想一想自己也没怎么学,32分也应该是比较正常的。最后大头劝我去复查分数,去学院教务处填了表,每天就呆在教师自习,受打击了!过了两个星期,再去看分数,给我找回来了。老师把我第一大题的分数当成总分了,现在70分了,有二等奖学金了,哈哈!但后来还是没把我的名字加上去,奖学金没了,证书没了,这一年的什么奖都没了。也没什么可惜的,正好刺激自己一下。

剩下的几个月,每天认认真真的学习,准备英语六级,无话可说。

总之,虽然2006年这一年没得到什么,甚至失去了好多,但既然已经过去,就让这些烦恼,这一切的一切,随风飘走吧。外面的阳光正灿烂,何必孤守自己回忆的一隅呢?

该失去的已经失去,该得到的也将得到,不必去争论,不必去强求。宠辱不惊,闲看庭前花开花落;去留无意,漫观天外云展云舒!

 

Leave a Comment

第一次成功优化Slackware Linux

参考1:http://www.linuxsir.org/bbs/showthread.php?t=68094

参考2:http://www.linuxsir.org/bbs/showthread.php?s=&threadid=85045

参考3:http://www.linuxsir.org/bbs/showthread.php?s=&threadid=133294

Step1 字体以及中文的显示问题

1. 更改英文为中文:修改 /etc/profile.d/lang.sh 找到一行是: export LANG=C 在它前面加#注释掉,然后增加一行: export LANG=zh_CN.gbk

2. 复制字体:创建/usr/share/fonts/;复制windows下面的simsun.ttf, tahoma*.ttf等字体到/usr/share/fonts/目录下

3.
修改XF86Config配置文件:修改/etc/X11/XF86Config 文件,加入路径: FontPath “/usr/share/fonts/” Section “Module” … Load “freetype” #<—– 这一行前面如果有#,应删除 Load “xtt” #<—– 这一行前面如果有#,应删除;如果没有这一行,自己加到文件里 Load “type1″ … EndSection

4. 下载或复制一些中文的ttf字体到 /usr/X11R6/lib/X11/fonts/TTF下

Step2 使用鼠标滚轮

改/etc/X11/xorg.conf。在mouse段的Option里,”protocol”设为“imps/2″,再加两行,最后成为: Option
“Protocol” “imps/2″ Option “Buttons” “5″ Option “ZAxisMapping” “4 5″ 或者另外一种说法: Section “InputDevice” # Identifier and driverIdentifier “Mouse1″Driver “mouse” Option “Protocol” “IMPS/2″ <==修改这里 Option “Device” “/dev/mouse” Option “Buttons” “5″ <==添加这里 Option “ZAxisMapping” “4 5″ <==添加这里

Step3 安装fcitx输入法

1.下载fcitx3.3 2.tar jxvf fcitx-3.3.tar.bz2 3.cd fcitx-3.3 4../configure 5.make 6.make install 7.make clean

Step4
安装LumaQQ

1.下载LumaQQ2005,解压 2.下载patch

Step5 slackware 9 普通用户不能访问mount的分区问题

更改/etc/fstab文件:/dev/hda10 swap swap defaults 0 0/dev/hda3 / ext3 defaults 1 1/dev/hda9 /boot ext3 defaults 1 2/dev/hda1 /mnt/winC vfat defaults,iocharset=gb2312,umask=022 1 0/dev/hda5 /mnt/winD vfat defaults,iocharset=gb2312,umask=022 1 0/dev/hda6 /mnt/winE vfat defaults,iocharset=gb2312,umask=022 1 0/dev/hda7 /mnt/winF vfat
defaults,iocharset=gb2312,umask=022 1 0/dev/hda8 /mnt/winG vfat defaults,iocharset=gb2312,umask=022 1 0/dev/cdrom /mnt/cdrom iso9660 noauto,owner,ro 0 0/dev/fd0 /mnt/floppy auto noauto,owner 0 0devpts /dev/pts devpts gid=5,mode=620 0 0proc /proc proc defaults 0 0###########/dev/hda7 /mnt/win vfat defaults,iocharset=gb2312,umask=022 1 0###########我改了winC-winD的defaults,原来是defaults

Step6
安装java和eclipse

1.j2sdk-1.4.2-nb-3.5-bin-linux.bin2.在~/bash_profile中加入JAVA_HOME=/opt/j2sdk_nb/j2sdk1.4.2/PATH=.:$JAVA_HOME/bin:$PATHexport CLASSPATH=$JAVA_HOME/jre/lib/rt.jar:$JAVA_HOME/lib/tools.jar:.export JAVA_HOME PATH3.eclipse-SDK-3.3M1-linux-gtk.tar.gz4.在/usr/local/bin中新建eclipse.sh:#!/bin/bash## 执行 eclipse 2.1.1#export Java_HOME=/opt/j2sdk_nb/j2sdk1.4.2export CLASSPATH=/opt/j2sdk_nb/j2sdk1.4.2/lib/opt/eclipse/eclipse -vm /opt/j2sdk_nb/j2sdk1.4.2/bin/java -data
/home/workspace &# -vm 参数用以指定使用哪一个 jvm 来执行Eclipse,# -date参数用以指定Eclipse的数据目录。在此指定其存在用户根目录(~)下的workspace目录中#将脚本保存到/usr/local/bin中,叫runeclipse.sh,并给runeclipse.sh分配755权限 ************************chmod -R 777 /home/workspace**************************

经过以上优化,系统基本可用了。以上优化对我的机器有效:联想旭日125F,Slackware9.0。本人 接触Linux的时间不长,上述方法如有不妥,请不吝赐教!

 

Leave a Comment