Q: How can you tell when you’ve reached Lisp Enlightenment?
A: The parentheses disappear.
* Anonymous
2010.03.17 Wednesday ACHK
Q: How can you tell when you’ve reached Lisp Enlightenment?
A: The parentheses disappear.
* Anonymous
2010.03.17 Wednesday ACHK
.
There are worse things than having people misunderstand your work. A worse danger is that you will yourself misunderstand your work.
— Paul Graham
.
.
.
2010.03.17 Wednesday
多次元宇宙 3
我們現在討論的「原因」是取其廣義,意思是「眾多先決條件之一」。而日常生活中的所講的「原因」,是取其狹義,意思是 「眾多先決條件中,最重要的一個」。
(安:問題是,怎樣才為之「先決條件」?)
如果事件 A 沒有發生,事件 B 就一定不會發生的話,事件 A 就為之事件 B 的「先決條件」。
「Not-A –> Not-B」 = 「A is one of the necessary conditions of B.」
例如,即使你「勤力讀書」,你都未必可以「高中狀元」。所以「勤力讀書」並不是「高中狀元」的充份條件 (sufficient condition)。
但是,你不「勤力讀書」的話,就完全沒有可能「高中狀元」。所以「勤力讀書」就是「高中狀元」的先決條件 (necessary condition)。
(安:如果事件 A 沒有發生,事件 B 就一定不可以發生 …)
「一定不可以發生」,就即是「一定不發生」。「一定不可以發生」和「一定不發生」的意思一樣。所以在這裡,「可以」這兩個字是多餘的。又例如,「我一定可以拿到諾貝爾獎」和「我一定拿到諾貝爾獎」意思是一樣的。所以「可以」這兩個字又是多餘的。
(安:如果這樣說的話,「一定會」中的「一定」都是多餘的。)
那又是。加了「一定」,意思上沒有任何增加,所以「一定會」中的「一定」意思上是多餘的。雖然意思上多餘,但是 presentation 上(表達效果上)可能不多餘,例如有加強語氣的作用。
— Me@2010.03.16
necessary condition = 先決條件 = 必要條件
2010.03.16 Tuesday (c) All rights reserved by ACHK
One of the quickest ways to increase your productivity on the computer is to go commando: stop using the mouse.
— Jeff Atwood
2010.03.16 Tuesday ACHK
.
你能不能發掘學生的優點, 透過那一個最大的優點來培養他的信心, 令他能在其他各方面都成功?
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
After leaving your school, the student should be able to say
.
“I feel good about myself.”
.
— A presentation by the Ying Wah primary school principal: Ms. Lam Woon Sum
— Me@29 Jun 2007, 10:09AM
.
.
.
2010.03.16 Tuesday
Past papers 8
“Past papers” means “past HKCEE/HKAL examination papers”. The topic is for Hong Kong students who are facing HKCEE or HKAL. But the general principles can also be used for tackling other public examinations.
這段改編自 2010年 1 月 3 日的對話。
.
KYH: 我覺得自己在 physics(物理)上沒有天份,因為我花了很多時間在 physics,也沒有什麼成效。
Me: 是不是讀書的方法錯了?
KYH: 不知呢 … 但是將同樣長度的時間放上另一科的話,例如 pure maths(純數學),我會很快上手。
Me: physics 都可以很快上手。
KYH: 真的嗎? 那我讀 physics 的方法可能是錯的。
Me: 你現在的 physics 老師和 pure maths 老師,哪一個教得比較好?
KYH: 兩個都不好,因為我們基本上都是自修的。 physics 老師隨便地將自己的意思講一下,之後就「飛書」,省略了大部分的內容,然後就叫我們自己溫習。
Me: 那就即是話你的 physics 老師根本沒有教到任何東西。那你的 pure maths 老師有教書嗎?
KYH: 有 … 其實都是我們自己讀 …
Me: 我的意思是,你的 pure maths 老師有沒有教實質內容?
KYH: 有 …
Me: 分別就在這裡! 一個有教實質內容,一個沒有教實質內容。根據你的說法,你的 physics 老師根本沒有教內容。
KYH: 我覺得是。他只是跟課文講一講就算。
Me: 所以就是說,即使你的 pure maths 老師都是教得不太好,不夠詳細,但是他起碼有教內容,起碼有教第一層基本功。所以主要問題是這個,而不是你有沒有 physics 天份的問題。當然,我現在講可能會太遲,因為距離考試只有三、四個月。你這麼遲才知道這點,想百分百補救是不可能的。你現在補救的話,大概只能拿到 B 級,拿不到 A 級成績。但是起碼你知道你 physics 讀得不好,不是你自己的問題,而是你的 physics 老師失職。
— Me@2010.03.15
.
.
2010.03.15 Monday (c) All rights reserved by ACHK
Recursive humor
A common joke (for example recursion in the Jargon File) is the following “definition” of recursion.
Recursion
See “Recursion”.
(Obviously, this recursion lacks the base case, so it will recur indefinitely.)
This is a parody on references in dictionaries, which in some cases may lead to circular definitions among related words. Jokes often have an element of wisdom, and also an element of misunderstanding. This one is also the shortest possible example of an erroneous recursive definition of an object, the error being the absence of the termination condition (or lack of the initial state, if looked at from an opposite point of view). Newcomers to recursion are often bewildered by its apparent circularity, until they learn to appreciate that a termination condition is key.
An example of this can be found by searching Google for the term “Recursion”. Google cleverly puts the searcher in an endless cycle, of suggesting “Recursion” as the word they were trying to spell, even though that's exactly the input they just used.
A variation is:
Recursion
If you still don't get it, see: “Recursion”.
which actually does terminate, as soon as the reader “gets it.”
— Wikipedia on Recursion
2010.03.15 Monday ACHK
.
One of the most useful mental habits I know I learned from Michael Rabin: that the best way to solve a problem is often to redefine it.
The way to kill it is to redefine the problem as a superset of the current one. The problem is not, what operating system should people use on desktop computers? but how should people use applications? There are answers to that question that don’t even involve desktop computers.
Everyone thinks Google is going to solve this problem, but it is a very subtle one, so subtle that a company as big as Google might well get it wrong. I think the odds are better than 50-50 that the Windows killer– or more accurately, Windows transcender— will come from some little startup.
— Paul Graham
.
.
.
2010.03.15 Monday
Design Philosophy of Sage
.
William Stein realized several important facts when designing Sage.
* To create viable alternatives to Magma, Maple, Mathematica, and MATLAB, would take hundreds, or thousands of man-years if one started from the beginning.
* There was a large collection of open-source mathematics software already written, but which was written in different languages (C, C++, Fortran and Python being the most common).
So rather than start from the beginning, Sage which is written in Python and Cython integrates all their specialized mathematics software into a common interface. A user needs to know only Python.
Where no open-source option exists for a particular class of problem, then this would be written in Sage. But Sage does not reinvent the wheel. The same design philosophy is used in commercial mathematics program such as Mathematica, but Sage can use a much wider range of open source software solutions than nonfree software, since some open source licensing imposes restrictions on commercial use of code.
— Wikipedia on Sage (mathematics software)
.
.
2010.03.14 Sunday ACHK
.
The problem here is not wealth, but corruption. So why not go after corruption?
We don’t need to prevent people from being rich if we can prevent wealth from translating into power.
How do you break the connection between wealth and power? Demand transparency. Watch closely how power is exercised, and demand an account of how decisions are made.
— Paul Graham
.
.
.
2010.03.14 Sunday
(安:「因果」是一個比喻空泛的一個概念 … 除了它有一個元素,就是「原因先於結果」。但是,除此之外,什麼是「因果」 呢?其實意思是迷迷糊糊的。)
其實可以這樣說:「不會無 A 而有 B」,那樣,A 就為之 B 的「因」。
(安:你的意思是將「原因」介定為「先決條件」?)
是。
(安:但是,你這個架構,和「原因」這個詞在日常生活的用法不相符。例如,有一件事件 B,它有十個先決條件:A1, A2, …, A10。要 A1, A2 … 到 A10 都發生了,B 才會發生。那樣,哪一個才算是 B 的原因呢?)
簡化起見,假設要 A, B, C 都發生了,D 才會發生。那我可以說「A, B, C 都是 D 的原因」。如果我說「A 是 D 的原因」的話,我都沒有錯,因為我不是說「A 是 D 的唯一原因」。
(安:如果根據你這個講法,「原因」這個詞就更加空泛:幾乎發生於 D 之前的任何事,都可以稱為 D 的原因。)
正正是這樣。所有在事件 D 的過去的事,都是事件 D 的原因。
(安:這樣用的話,會令到「原因」這個詞空泛到完全沒有意義。)
這裡,「原因」這個詞,其實已化成「時間」的意思。「原因」就即是「過去」。當我們說事件 A 是事件 D 的「原因」,其實即是話 A 在 D 的過去。
(安:這個講法很奇怪,而且遺反了日常生活中「原因」這個詞的用法。例如,我說「我有好成績的原因是我有努力讀書。」意思並不只是 「『努力讀書』是在『拿到好成績』的過去。」)
所以要非常小心。我們現在討論的「原因」是取其廣義,意思是「眾多先決條件之一」。而日常生活中的所講的「原因」,是取其狹義,意思是 「眾多先決條件中,最重要的一個」。
— Me@2010.03.13
2010.03.13 Saturday (c) All rights reserved by ACHK
Apple
Schmidt was elected to Apple’s board of directors on August 28, 2006. On August 3, 2009 it was announced that Schmidt would resign his board member position at Apple due to conflict of interests and the growing competition between Google and Apple.
— Wikipedia on Eric E. Schmidt
2010.03.13 Saturday ACHK
.
Good runners still get tired; they just get tired at higher speeds.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
If you feel exhausted, it’s not necessarily because there’s something wrong with you. Maybe you’re just running fast.
— Paul Graham
.
.
.
2010.03.13 Saturday
Past papers 7
“Past papers” means “past HKCEE/HKAL examination papers”. The topic is for Hong Kong students who are facing HKCEE or HKAL. But the general principles can also be used for tackling other public examinations.
這段改篇自 2010年 1 月 3 日的對話。
LKF:我覺得現在的溫習進度不行…
Me:”不行” 是什麼意思? “不行” 可以是指不合格,又可以指拿不到最好成績(A 級)。
LKF:不知呀 … 我現在只有 chemistry (化學)一科行。
Me:”行” 是什麼意思?
LKF:都應該可以取到 B (B級成績)。
…
Me:哪這一科是不是十分穩陣(安全)?
LKF:應該好穩陣。
Me:你有沒有試過計時計分做歷屆試題(pastpaper)?
LKF:還沒有。
Me:那就不太安全。因為你現在只是憑感覺,認為自己行,沒有客觀的成績做參考。萬一你的感覺錯了,哪怎麼辦呢?
最好是每一次也 限時間 計分數 按年份 做 pastpaper。那樣你就可以知道自己在考試的指定時間內,可以拿到什麼分數,達到什麼水平。還有,你未必每一次也有時間做整整一年的 pastpaper。例如 2006 年的 pastpaper 包括 paper 1 和 paper 2(卷一和卷二),共要六小時完成。但是你某一日只有三小時,不能完成 2006 年整份 pastpaper。那也沒有所謂。你可以一日用三小時做 paper 1,下一日用三小時做 paper 2。重點是要 限時間 和 計分數。
你知不知多少分對應什麼 grade(等級)?
LKF:不是太清楚。
Me:我認為現在你們最大的問題是 不知己又不知彼。知彼的意思是 知道什麼分拿什麼 grade;知己的意思是 知道自己可以拿到多少分數。這些都是一定要問清楚、搞清楚的資料。還有,要得到這些資料是簡單容易的事情。要知彼,你可以問老師,他們一定會知道什麼分拿什麼 grade;要知己,你限時間做 pastpaper,完成後立刻為自己批改,就可以知道自己的水平。
自信不是建基於才華出眾;自信不是建基於沒有困難;自信來自於對自己的了解;自信來自於對客觀環境的了解。
— Me@2010.03.12
2010.03.12 Friday (c) All rights reserved by ACHK
Category Theory | Lisp 3
Haskell is very obviously a language built by mathematical logicians for mathematical logicians. Category theory lurks behind it in the same way that the lambda calculus lurks behind LISP.
— Eric S. Raymond
2010.03.12 Friday ACHK
.
照亮他人……
……毋須燃燒自己
— Me@2007.10.17
.
.
.
2010.03.12 Friday
Avram Noam Chomsky (born December 7, 1928) is an American linguist, philosopher, cognitive scientist, political activist, author, and lecturer.
Influence in other fields
Chomskyan models have been used as a theoretical basis in several other fields. The Chomsky hierarchy is often taught in fundamental computer science courses as it confers insight into the various types of formal languages. This hierarchy can also be discussed in mathematical terms and has generated interest among mathematicians, particularly combinatorialists. Some arguments in evolutionary psychology are derived from his research results.
The 1984 Nobel Prize laureate in Medicine and Physiology, Niels K. Jerne, used Chomsky’s generative model to explain the human immune system, equating “components of a generative grammar … with various features of protein structures”. The title of Jerne’s Stockholm Nobel lecture was “The Generative Grammar of the Immune System”.
— Wikipedia on Noam Chomsky
2010.03.11 Thursday ACHK
.
If you begin by sacrificing yourself to those you love, you will end by hating those to whom you have sacrificed yourself.
* Self-Sacrifice
— George Bernard Shaw
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
天使, 犧牲自己的利益來追求自己的理想.
魔鬼, 犧牲別人的利益來追求自己的理想.
傻瓜, 犧牲自己的理想來追求別人的利益.
智者, 透過實現自己的理想來追求別人的利益.
— Me@2009.09.14, 2010.03.11
.
.
.
2010.03.11 Thursday
Multi-dimensional universe
上次你說有關 multi-dimensional 的問題。你可不可以由第一句開始講?
(安:Multi-dimensional … 時間 … 其實我不太記得上次我們說了什麼 …)
我們說有關 points of view 的問題。有時候我的講法和你的講法不同。然後我說,”看法不同” 這個現象可以比喻成,我們其實看著同一個 object(物件),只不過我們各自 由不同的角度去觀察它。
(安:哪和時間有什麼關係呢?)
你上次問,雖然我用了 multi-dimensional universe(多次元宇宙)來比喻 “本體”,但是我這個比喻沒有處理到宇宙萬物的 “因果關係”。接著,我就說,multi-dimension 的其中一個次元就是 ”時間”。而 ”時間”,就是 ”因果網絡”。所以,我這個比喻,已經包括了 “因果關係”。
…
(安:”因果” 是一個比喻空泛的一個概念 … 除了它有一個元素,就是 ”原因 先於 結果”。但是,除此之外,什麼是 ”因果” 呢?其實意思是迷迷糊糊的。)
其實可以這樣說: “不會無 A 而有 B ” ,那樣,A 就為之 B 的 “因”。
(安:你的意思是將 ”原因” 介定為 ”先決條件”?)
是。
— Me@2010.02.10
2010.03.10 Wednesday (c) All rights reserved by ACHK
With Lisp (Scheme/Common Lisp), you can write programs to write programs.
With Category theory, you can unify the mathematics of General Relativity and the mathematics of Quantum Mechanics.
— Me@2010.03.09
2010.03.10 Wednesday (c) All rights reserved by ACHK
You must be logged in to post a comment.