Windows XP系统中用户帐号面板空白解决的方法

2010年3月4日 pighead 没有评论

虽然XP都快要被淘汰了,但是有用的东西还是转一下

这种情况为

1)内核文件损坏或者

如果是内核文件损坏,那就比较麻烦,只有重新安装系统了.

2)内核文件被修改
可以在 开始-运行中输入sfc    /scannow,然后按回车,放入系统盘,按提示完成就可以了。

或者直接在 开始-运行中输入以下命令,每输入一个命令按一下回车。

regsvr32 nusrmgr.cpl
regsvr32 mshtml.dll
regsvr32 jscript.dll
regsvr32 /i shdocvw.dll
regsvr32 vbscript.dll
regsvr32 appwiz.cpl
regsvr32 msi.dll
regsvr32 mshtmled.dll
regsvr32 /i shell32.dll

分类: 随便说说 标签:

有空好好学习吧

2010年3月4日 pighead 没有评论

小滴如是说,我觉得也是,在社区大学最后一年,整个人都变懒了……

第一次同一天连续两个考试(真正的连续啊,4:30pm考到6:30pm,然后开车到另一个学校7:00pm再开始考),第一次考完完全没感觉也预测不到grade

看来真的要像小滴说的,有空好好学习

原来这个不是中国特色嘛……

2010年3月1日 pighead 2 条评论

在cnbeta看到一篇名为 《不会编程的程序员》 的文章,原文是其实更有趣,不过是英文来着的 “Why Can’t Programmers.. Program?” 里面那个简单的程序我也大概花了5-10分钟编出来吧,但只停留在能出来结果的层面,还不够简洁,不知道实际面试的时候会不会要求消耗最小的资源来达到目的呢?

看来程序员不会编程不单单是中国才有的,是一国际性的东西。

不会编程的程序员

分类: Programming, Scheme 标签:

算法果然是王道

2010年2月27日 pighead 2 条评论

这个学期有两堂的programming课,果然algorithm和construction才是重中之重啊……越来越觉得自己很笨

分类: Scheme 标签: ,

村上春樹在耶路撒冷演講

2010年2月16日 pighead 没有评论

转自一五一十部落

**引用開始**

「Always on the side of the egg 永遠站在雞蛋的一側」

Good evening. I have come to Jerusalem today as a novelist, which is to say as a professional spinner of lies.

各位晚上好,我今天作為一名小說家來到耶路撒冷的,也就是說一名職業謊言製造者。

Of course, novelists are not the only ones who tell lies. Politicians do it, too, as we all know. Diplomats and generals tell their own kinds of lies on occasion, as do used car salesmen, butchers and builders. The lies of novelists differ from others, however, in that no one criticizes the novelist as immoral for telling lies. Indeed, the bigger and better his lies and the more ingeniously he creates them, the more he is likely to be praised by the public and the critics. Why should that be?

當然,並不是只有小說家才說謊的。政治家也說謊,正如大家所知道的。外交官和將軍有時也要說著他們自己的謊言,就如同二手 車推銷員、劊子手以及建築師一樣。但是,小說家的謊言與其他人不一樣,因爲沒有人會批評小說家,稱他們說謊不道德。實際上,小說家的謊言說得越大越好,編 造謊言的能力越高明,他才更可能受到公衆和評論家的認可和好評。這是爲什麽呢?

My answer would be this: namely, that by telling skilful lies–which is to say, by making up fictions that appear to be true–the novelist can bring a truth out to a new place and shine a new light on it. In most cases, it is virtually impossible to grasp a truth in its original form and depict it accurately. This is why we try to grab its tail by luring the truth from its hiding place, transferring it to a fictional location, and replacing it with a fictional form. In order to accomplish this, however, we first have to clarify where the truth-lies within us, within ourselves. This is an important qualification for making up good lies.

我的答案是:通過更有技巧地說謊——也就是說,創作看起來似乎是真實的小說——小說家才能夠将真相帶到新的地方,才能讓新的陽光 撒到這片新的土地上。在多數情況下,幾乎不可能以其原始形式掌握真相,也不可能準确地闡述真相。這就是爲什麽我要将真相從衆多掩蓋之中拉出來,将它放到一 個虛幻的地方,再用一種虛幻的形式将它替代。但是要想做到這一點,我們首先要清楚真實的謊言在我們心中,就在我們自己的心中。這是要想編造完美謊言的一個 非常重要的資質。

Today, however, I have no intention of lying. I will try to be as honest as I can. There are only a few days in the year when I do not engage in telling lies, and today happens to be one of them.

但今天,我并不想說謊。我會盡可能地做到誠實。這也是一年當中我不說謊的爲數不多的幾天之一,今天碰巧就是其中之一。

So let me tell you the truth. In Japan a fair number of people advised me not to come here to accept the Jerusalem Prize. Some even warned me they would instigate a boycott of my books if I came. The reason for this, of course, was the fierce fighting that was raging in Gaza. The U.N. reported that more than a thousand people had lost their lives in the blockaded city of Gaza, many of them unarmed citizens–children and old people.

讓我來告訴你們真相。在日本有許多人建議我不要來這裏接受“耶路撒冷文學獎”。甚至有些人警告我,如果我要堅持來的 話,他們就會掀起抵制閱讀我的小說的活動。當然,原因是加沙的戰争正如火如荼。據聯合國報道,已經有一千多人在已封鎖的加沙城失去了他們的生命,許多都是 手無寸鐵的平民——孩子和老人。

Any number of times after receiving notice of the award, I asked myself whether traveling to Israel at a time like this and accepting a literary prize was the proper thing to do, whether this would create the impression that I supported one side in the conflict, that I endorsed the policies of a nation that chose to unleash its overwhelming military power. Neither, of course, do I wish to see my books subjected to a boycott.

在接到這個獲獎通知後我不斷地問自己,是否要在這樣一個特殊時刻來耶路撒冷,接受這樣的文學獎是否是現在該做的事情,這樣做是否會讓人産生一種印象,說我支持沖突中的其中一方,說我支持選擇向世界展示其龐大軍事力量的國家的政策呢。當然我也不希望看到我的書遭到抵制。

Finally, however, after careful consideration, I made up my mind to come here. One reason for my decision was that all too many people advised me not to do it. Perhaps, like many other novelists, I tend to do the exact opposite of what I am told. If people are telling me– and especially if they are warning me– “Don’t go there,” “Don’t do that,” I tend to want to “go there” and “do that”. It’s in my nature, you might say, as a novelist. Novelists are a special breed. They cannot genuinely trust anything they have not seen with their own eyes or touched with their own hands.

但最後在經過深思熟慮後,我還是決定來到耶路撒冷。我之所以做出這樣的決定,原因之一就是有太多的人不想讓我來這裏。 可能與許多其他小說家一樣,我總是要做人們反對我做的事情。如果人們對我說——并且特别是如果他們警告我——“不要去那裏”、“不要這樣做”,我就偏偏要 去那裏,偏偏要這樣做。你可能會說,這就是小說家的性格。小說家是另類。如果他們沒有親眼所見,沒有親手觸摸,他們是不會真正相信任何事情的。

And that is why I am here. I chose to come here rather than stay away. I chose to see for myself rather than not to see. I chose to speak to you rather than to say nothing.

這就是我來到這裏的原因。我選擇來這裏,而不是逃避。我選擇親自來看一看,而不是回避,我選擇在這裏向大家說幾句,而不是沉默。

Please do allow me to deliver a message, one very personal message. It is something that I always keep in mind while I am writing fiction. I have never gone so far as to write it on a piece of paper and paste it to the wall: rather, it is carved into the wall of my mind, and it goes something like this:

請允許我在這裏向你們傳遞一條信息,是一個非常私人的信息。在我寫小說時我總是在心裏牢記,但我從來都不會把它寫在紙上,貼在牆上,我是把它刻在了心靈的牆上,這條信息是這樣的:

“Between a high, solid wall and an egg that breaks against it, I will always stand on the side of the egg.”

“在一座高大堅實的牆和與之相撞的雞蛋之間,我永遠都站在雞蛋的一側”。

Yes, no matter how right the wall may be and how wrong the egg, I will stand with the egg. Someone else will have to decide what is right and what is wrong; perhaps time or history will do it. But if there were a novelist who, for whatever reason, wrote works standing with the wall, of what value would such works be?

是的,無論牆是多麽的正确,雞蛋是多麽地錯誤,我都站在雞蛋的一側。其他人可能會判斷誰是誰非,也許時間或歷史會來判斷。但是,如果一個小說家無論因何種原因站在牆的一側來創造,那麽他的作品的價值何在呢?

What is the meaning of this metaphor? In some cases, it is all too simple and clear. Bombers and tanks and rockets and white phosphorus shells are that high wall. The eggs are the unarmed civilians who are crushed and burned and shot by them. This is one meaning of the metaphor.

這個比喻是什麽意思呢,在有些時候,非常簡單明了。轟炸機、坦克、火箭以及白磷彈就是那堵高牆,雞蛋是被這些武器毀滅、燒傷并擊斃的手無寸鐵的百姓。這就是這個比喻的其中一層含義。

But this is not all. It carries a deeper meaning. Think of it this way. Each of us is, more or less, an egg. Each of us is a unique, irreplaceable soul enclosed in a fragile shell. This is true of me, and it is true of each of you. And each of us, to a greater or lesser degree, is confronting a high, solid wall. The wall has a name: it is “The System.” The System is supposed to protect us, but sometimes it takes on a life of its own, and then it begins to kill us and cause us to kill others–coldly, efficiently, systematically.

但是,并不僅僅是這些。它還 有更深一層的含義,我們來這樣考慮一下,我們中的每一個人或多或少都是一個雞蛋。我們中的每一個人都是存在于一個脆弱外殼中唯一的、不可替代的靈魂。我也 一樣,對你們中的每一個人也一樣。并且,我們中的每一個人在某種程度上也面臨着一堵高大堅實的牆。這個牆有一個名字:那就是“體制”。這個體制本來是要保 護我們的,但是有時候它會呈現出它自己的一面,然後就開使殘殺我們,并使我們去殘殺他人——冷酷、有效、系統地殘殺。

I have only one reason to write novels, and that is to bring the dignity of the individual soul to the surface and shine a light upon it. The purpose of a story is to sound an alarm, to keep a light trained on the System in order to prevent it from tangling our souls in its web and demeaning them. I truly believe it is the novelist’s job to keep trying to clarify the uniqueness of each individual soul by writing stories–stories of life and death, stories of love, stories that make people cry and quake with fear and shake with laughter. This is why we go on, day after day, concocting fictions with utter seriousness.

我 寫小說只有一個原因,那就是要給予每一個靈魂以尊嚴,并且讓他們接受陽光的沐浴。情節的目的聽起來是一種警報,是對體制進行光芒的培訓,阻止它將我們的靈 魂纏結在它的圈套中,防止踐踏我們的靈魂。我忠實地相信,小說家的職責就是通過創作故事——關于生死、關于愛情、讓人哭泣和顫慄以及讓人大笑不已的故事, 讓人們意識到每一個靈魂的唯一性。這就是我不停創作的原因,日復一日,以十分嚴肅的態度創作小說。

My father passed away last year at the age of ninety. He was a retired teacher and a part-time Buddhist priest. When he was in graduate school in Kyoto, he was drafted into the army and sent to fight in China. As a child born after the war, I used to see him every morning before breakfast offering up long, deeply-felt prayers at the small Buddhist altar in our house. One time I asked him why he did this, and he told me he was praying for the people who had died in the battlefield. He was praying for all the people who died, he said, both ally and enemy alike. Staring at his back as he knelt at the altar, I seemed to feel the shadow of death hovering around him.

我的父親是在去年去世的,享年九十歲。他是一名退休教 師,是一名兼職佛教高僧。他從京都的研究生院畢業後,應征入伍,被派到中國打仗。作爲一個戰後出生的孩子,我每天早晨在早飯前,總是看到他的在我家的小佛 教祭壇前非常虔誠地長時間地祈禱。有一次我就問父親爲什麽要這樣做,他就告訴我說,他是在爲戰争中死去的人們祈禱。他說,他爲所有死去的人祈禱,無論是同 盟還是敵人。當我看着他跪在祭壇前的背影時,我似乎感受到了萦繞在他周圍的死亡的陰影。

My father died, and with him he took his memories, memories that I can never know. But the presence of death that lurked about him remains in my own memory. It is one of the few things I carry on from him, and one of the most important.

我的父親去世了,帶着他的記憶,我永遠都不可能知道的記憶。但是環繞在他周圍的那些死亡卻留在了我自己的記憶中。這是我從他那裏學習到東西之一,也是最重要的東西之一。

I have only one thing I hope to convey to you today. We are all human beings, individuals transcending nationality and race and religion, and we are all fragile eggs faced with a solid wall called The System. To all appearances, we have no hope of winning. The wall is too high, too strong–and too cold. If we have any hope of victory at all, it will have to come from our believing in the utter uniqueness and irreplaceability of our own and others’ souls and from our believing in the warmth we gain by joining souls together.

今天我只希望向你們傳達一個信息。我們都是 人類,是超越國籍、種族和宗教的個體的人,我們都是脆弱的雞蛋,要面臨被稱作“體制”的堅實的牆。從外表來看,我們根本就沒有赢的希望。這堵牆太高太堅實 ——并且太冷酷了。如果我們有一點戰勝它的希望,那就是來源于我們對我們自己以及他人靈魂唯一性和不可替代性的信念,來源于我們對将靈魂聯合起來可獲得溫 暖的信念。

Take a moment to think about this. Each of us possesses a tangible, living soul. The System has no such thing. We must not allow the System to exploit us. We must not allow the System to take on a life of its own. The System did not make us: we made the System.

花一點時間來考慮這些,我們每一個人都擁有有形的生動的靈魂,而體制沒有。我們不能讓體制來剝削我們。我們不能讓體制現出它自己的一面。不是體制創造了我們,而是我們建立了體制。

That is all I have to say to you.

這就是我想要對你們說的。

I am grateful to have been awarded the Jerusalem Prize. I am grateful that my books are being read by people in many parts of the world. And I would like to express my gratitude to the readers in Israel. You are the biggest reason why I am here. And I hope we are sharing something, something very meaningful. And I am glad to have had the opportunity to speak to you here today.

非常感謝授予了我耶路撒冷文學獎。我也非常感謝世界各地有那麽多人看了我寫的書。我還要感謝以色列的讀者們。你們是我來到這裏的最主要原因。我希望我們能夠分享一些東西,一些有非常有意義的東西。我也非常高興今天有機會在這裏發言。

Thank you very much.

謝謝大家。

**引用結束**

分类: 随便说说 标签:

Scheme: trace function

2010年2月16日 pighead 没有评论

I will record the experience or some useful command here.

The first one is used to trace a function calls, very useful.

>(trance func)

func is the function you define.

The next time you invoke func you will see the trace of function calls.

分类: Scheme 标签:

WIN7下Live Message在任务栏出现两个任务的解决办法

2010年1月22日 pighead 1 条评论

在WIN7使用Live Message的过程中,发现LM会在WIN7的任务栏出现两个任务,一个是LM的默认窗口,一个是以我的ID登录后的窗口。其实两者是同一个东西,我不明白为什么MS要搞成这个样子。一开始懒得搞,后来越看越不顺眼,上网一google原来大家都不喜欢,然后也有了解决方法:

How to Have Windows Live Messenger with a Windows 7 Taskbar or Tray Icon

分类: 随便说说 标签:

让代码更美:10大编程字体

2010年1月20日 pighead 没有评论

转载自三秒

日复一日的编写代码,有没有感到审美疲劳?也许些许的改变就能让我们感到生活更美好。

换一种编程字体吧!体验一种新的代码感觉。

下面我眼中的十大编程字体:

10. Courier

基本上所有的系统都自带了此种字体,有时候它又以Courier New的名字出现。不幸的是很多终端和编辑器都默认使用此种字体,虽然这不会影响使用,但这会影响心情,它太枯燥了。以前看到这样一句评论:久不见牡丹会以仙人掌为美。这句评论形Courier字体非常合适。所以如果你还有其他选择的话,请勿使用此字体。更不幸的事情是最后你还是会继续使用它,那3秒只能强烈建议你调整一下字体大小并消除锯齿。

9. Andale Mono

稍微比Courier好一点的字体,有些时候它也被用作默认字体。3秒给它的定义是:一个软件不自带就不会有人去专门下载使用的一种字体。

8. Monaco

使用苹果Mac的人们对它不陌生,它是Mac的默认字体,3秒的经验是:使用它时,把字体设置为9号或者10号时会更好,这样看起来就相对不寒酸了。

7. Profont

Profont是一种类Monaco的位图字体,你能够在Mac, Windows和Linux上面使用,Mac平台的ProFontX就是它的修改版,当然两个字体并非出自同一作者之手。如果使用它,你把字体调小一点为好。而且如果你是非Mac平台,它是Monaco的最佳替代者。如果你喜欢微小字体或者喜欢眼疲劳,你可以考虑一下它。

6. Monofur

Monofur是一种独特的等宽字体,各种大小看起来都非常不错,前提是你已经设置为消除锯齿。这种字体的外观比较独特,看着它容易让你想起上世纪八十年代Sun的Solaris(SunOS)上的OPENLOOK窗口管理器。如果你喜欢新鲜的东西,你可以试一下这种字体,再次提示一下:消除锯齿。

5. Proggy

Proggy是一种很干净的等宽字体,貌似受到很多Windows用户的青睐,在Mac上它同样工作正常。使用它一般把字体调小点,不要消除锯齿。

4. Droid Sans Mono

Droid 字体家族 适合手机等小屏幕的移动平台,比如Android。它在Apache许可证下授权。伟大的编程字体,在我列出的等宽字体中它是最突出的一个。

3. Deja Vu Sans Mono

Deja Vu 是我最喜欢的免费字体家族之一,基于Vera字体家族。Deja Vu已经能够支持更多的字符了,并保持了Vera的外观和感觉。适于任何大小,只要你消除锯齿。

2. Consolas

Consolas是商业字体,它是Luc(as) de Groot为微软ClearType字体家族设计的,与微软很多产品绑定在一起,所以幸运的是可能你的系统上已经有它的存在了。如果你在不消除锯齿的情况下使用它,那还不如使用Courier吧!

1. Inconsolata

Inconsolata是我最喜欢的等宽字体,而且是免费的。在发现它之后,3秒迅速改变了Deja Vu Sans Mono作为我默认编程字体的情况。从终端窗口到代码编辑器,我让它无处不在。它的风格非常独特。设计它的时候就已经把锯齿消除了,就算是非常小的时候也很清晰—真正的情况是它适合于任何大小。感谢Raph Levien创造了Inconsolata,并让它免费。


这些字体中大部分是免费的,可以自由下载。有些是是商业软件的一部分,比如Consolas。

你感觉怎么样?如果感觉相见恨晚,不妨去尝试一下。

原文 http://3seconds.cn/2010/01/20/10-programming-fonts.html

分类: 小道消息 标签:

Rainbow

2009年7月14日 林胖胖 2 条评论

唱卡拉OK时在门口巧遇的大彩虹,说巧遇是因为一开始我根本没发现它,过马路的时候突然看到隔壁路上有辆车载等绿灯,车里的人拿着手机向我的方向照过来。我非常奇怪,干嘛照我呢?扭头过去,才发现他是在照这条大彩虹。

用户插入图片

分类: 加州流浪记 标签:

【转帖】在H1NI边缘游走

2009年6月21日 林胖胖 没有评论

PH童鞋突然毫无声息地从加州回来了,周六在看房子的时候突然接到了个陌生的电话,听见PH的声音时完全无法回神过来,就那么突然地,PH降临canton料。

在经过「你究竟隔离了几天」&「有无带手信给我」的「拷问」,并确认了PH的答复是「2号回来,已经自我隔离过」&「有带手信给我」后,遂约定周末聚餐→话说小妖是一个多么重义气的人哇,完全是冒着生命危险赴宴诶。

关于聚餐地点,第一反应是去「漓江又一轩」,话说我真的对那里的田螺念念不忘呢!而且口瘾突然就上来了的样子,但是考虑到天河北那个地方附近没地铁站,怕PH不好找地点,遂临时改为了「金本涮涮锅」。

可是,大概上天注定要满足的我口瘾的样子,金本涮涮锅竟然订不到位置,遂再次改回去「漓江又一轩」。反正在我征集意见时,PH也说了,田螺嘛,他不是特别爱吃,但是也不会排斥。OK,那就行了,大不了点多两份米饭给他咯。

事实证明,老天只是和我开个玩笑而已。我深刻地体会到,像「吃田螺」这么「曲高和寡」的事情,一定要志同道合者一起才能吃得畅快淋漓。

虽说我虽然一开始为「无人与我争食」感到非常兴奋,并雄心勃勃地决定要点上两三份才罢休,可是后来看着PH&GG把田螺当成「法国蜗牛」吃
的阵势「完全的慢条斯理啊」,便不由吃兴减弱,继而战斗力大大下降,最后竟然只是吃了1/2碟田螺便「鸣鼓收兵」,甚至连那盆招牌菜「山寨田螺鸡」都不大
曾涉足,最厉害的是这两个人还让我怀疑起「我喜欢这间店的理由」,并产生了「两个月内不要再来这间店吃」的念头,囧。

最让我不爽的是GG竟然和PH一见如故,两个人一副相见但恨晚的样子,聊得欢快,完全把我晾到一边,让我不仅产生「其实GG和PH才是旧识而我只是搭台」的想法,囧。

PH童鞋经受米国的磨练后,整个人沉稳了许多,和印象&电话中那个「放荡不羁」的PH童鞋差之深远哇,令小妖产生「士别三日刮目相看」的感概,难道真的是「国外的空气特别清新」么?→其实我很怀疑他只是碍于我家GG在场而把猪尾巴藏了起来而已。

没错,一定是这样的,因为PH在电话里面承诺的手信竟然只是米国的口香糖一条,我怒。PH你最好告诉我听米国的口香糖有预防H1NI的功效,否则,哼,没完。

话说PH童鞋身处FB的米国,体形不见增长,反而整个大饼脸成了瓜子形,身材也非常苗条,以致GG开始质疑我之前给他看的PH的照片给错了,囧。但
很快我就发现了真相,经过互拍&偷拍后,小妖发现原来PH童鞋真的是一个超级不上镜的人,那个瓜子脸一到了我的相机里面又成了完美的圆弧形,哈哈
哈哈。

晚餐完毕我们打的送PH去地铁,期间大聊「猪流感」&「隔离」&「国外归来」等话题,以致后来……是我的错觉吗?为啥我总觉得司机把车开得越来越快呢?哈哈哈哈。

埋单的时候PH童鞋承诺等我去了米国就会回请之,好,开始存钱吧,我去吃米国吃大餐,瓦咔咔。

分类: 精神修为 标签: