否定文に対する回答

昨日の英語の時間のあとに、クラスの牛山君が先生に質問していたのを一緒に聞いてた。

英語では「Are you NOT a programmer?」という質問に対して、もし本当にプログラマーなら「Yes(, I am).」と答えて、もし違うなら「No(, I am not).」と答えるんだって。

日本語だと、「プログラマーじゃないの?」って質問に対して「うん」って言ったら逆にその人はプログラマーじゃないことになるのにねー。ややっこしいよー><。

ぁれ? でも、日本語の方が変なのかな。日本語の場合、「はい」「いいえ」は質問に対しての文法上の答えというよりも、質問が意味するところまで考えて、「その内容は真実です」または「偽りです」と答えてることになるよね。深いな  ̄▽ ̄ キラーン

どっちかとゆーと、日本語の Yes/No は True/False に近い? のかな? かな?

0 (ゼロ) の代入方法

Noun が 1/-1、その前に Adjuctive を置くと x2 で、あれ? 0 は? 変数初期化できないよ? と思ってたんだけど、constant のリストを見ていたらやっぱりあった。

$NOTHING
nothing
zero

だから

You are nothing.

とかって書けば 0 が代入されるみたい。You are nothing but stupid^^

あ、エラーでた^^;

$NEGATIVE_NOUN に変なのがあった(笑)

まずは constant をある程度覚えようと思って Shakespeare.pm の中をのぞいていたの。そしたら、

$NEGATIVE_NOUN
Hell
Microsoft
bastard
beggar
blister
codpiece
coward
curse
death
devil
draught
famine
flirt-gill
goat
hate
hog
hound
leech
lie
pig
plague
starvation
toad
war
wolf

$NEGATIVE_NOUN のリストの中に「Microsoft」があったよ!(ノ∇≦、)ノ彡☆ キャハハ!!バンバンッ!!

しかも上から二番目(笑)。よくわからないけど、Hell の次に思いつくほどネガティブなの?  ̄▽ ̄;

これはこの CPAN オーサーのジョークなのかなぁ。GCC のパッケージではもしかしたら別? 自分でちゃちゃっと足せるから面白いね^^。私も何か足そうかなぁ。「homework」とか><。。

冠詞を置かないで起こるエラー

あうー

引き続き Shakespeare 書いてるんだけど、

You are flower.

だと「contant expected」ってエラーが出るんですね!!><、

正しくは、冠詞 (Article) として「a」や「an」や「the」を名詞 (Noun) の前に置かなきゃならないらしいんだけど、チュートリアルだと constants は Noun って言われているから、ちゃんと名詞あるじゃん!!! ってなってずっとハマってたよ〜 へ(゜∇、°)

とゆーわけで

You are a flower.

でおっけー!(^^)b

あとそれから、

You are as beautiful as flower.

と書いた場合はエラーメッセージが「value expected」になりました(笑)。同じく冠詞を書かなかったことで起こるエラーなのに! ややっこしいしね(笑)

Shakespeare Programming Language★

今日の一時間目の英語でコンピューター室へ行って Shakespeare Programming Language (SPL: シェイクスピアプログラミング言語) というのを習った。GCCコンパイルするのは面倒臭いので、Perl での実装を使ってローカルのコマンドラインから Hello, World プログラムを実行してみたよ。

ソース:

use Lingua::Shakespeare;

The Infamous Hello World Program.

Romeo, a young man with a remarkable patience.
Juliet, a likewise young woman of remarkable grace.
Ophelia, a remarkable woman much in dispute with Hamlet.
Hamlet, the flatterer of Andersen Insulting A/S.


                    Act I: Hamlet's insults and flattery.

                    Scene I: The insulting of Romeo.

[Enter Hamlet and Romeo]

Hamlet:
 You lying stupid fatherless big smelly half-witted coward!
 You are as stupid as the difference between a handsome rich brave
 hero and thyself! Speak your mind!

 You are as brave as the sum of your fat little stuffed misused dusty
 old rotten codpiece and a beautiful fair warm peaceful sunny summer's
 day. You are as healthy as the difference between the sum of the
 sweetest reddest rose and my father and yourself! Speak your mind!

 You are as cowardly as the sum of yourself and the difference
 between a big mighty proud kingdom and a horse. Speak your mind.

 Speak your mind!

[Exit Romeo]

                    Scene II: The praising of Juliet.

[Enter Juliet]

Hamlet:
 Thou art as sweet as the sum of the sum of Romeo and his horse and his
 black cat! Speak thy mind!

[Exit Juliet]

                    Scene III: The praising of Ophelia.

[Enter Ophelia]

Hamlet:
 Thou art as lovely as the product of a large rural town and my amazing
 bottomless embroidered purse. Speak thy mind!

 Thou art as loving as the product of the bluest clearest sweetest sky
 and the sum of a squirrel and a white horse. Thou art as beautiful as
 the difference between Juliet and thyself. Speak thy mind!

[Exeunt Ophelia and Hamlet]


                    Act II: Behind Hamlet's back.

                    Scene I: Romeo and Juliet's conversation.

[Enter Romeo and Juliet]

Romeo:
 Speak your mind. You are as worried as the sum of yourself and the
 difference between my small smooth hamster and my nose. Speak your
 mind!

Juliet:
 Speak YOUR mind! You are as bad as Hamlet! You are as small as the
 difference between the square of the difference between my little pony
 and your big hairy hound and the cube of your sorry little
 codpiece. Speak your mind!

[Exit Romeo]

                    Scene II: Juliet and Ophelia's conversation.

[Enter Ophelia]

Juliet:
 Thou art as good as the quotient between Romeo and the sum of a small
 furry animal and a leech. Speak your mind!

Ophelia:
 Thou art as disgusting as the quotient between Romeo and twice the
 difference between a mistletoe and an oozing infected blister! Speak
 your mind! Open your heart.

[Exeunt]

結果:

Hello, World!

ところで、はてなダイアリーの「ソースコードを色付けして記述する(シンタックス・ハイライト)」には spl のシンタックスカラースキームが定義されていなくて悲しいよ><。 はてなアイデアにお願いすれば作ってくれるのかなぁ……

シェークスピアのハムレット

今日の英語の授業のとき、図書室へ行って英語の本を一冊ずつ持って来いと言われたので、友達の祐ちゃんと一緒に探していたらいっぱいあった。みんなは『ウォーリーを探せ』とか絵本とかを持っていったけど、私は『ハムレット (Hamlet)』にしました。

教室に帰って、同じ班の人と見せ合いっこしていたら、先生が「シェークスピアは古くて難しいけどとても美しい」と言っていました。英語の美しさってよくわからないけど、頑張って読んでみようかなあ

グラマーって意味なさそう

前までアメリカに行ってたぉじきが言ってたンだけど、ぃくら文法をぃっぱぃ覚えても、むこうの人とぃっぱぃ話せるようにはならないんだって><。

なぉみも中学校になったら英語の時間が増えるけど、意味ぁるのかなぁ……