Kelobyte

Saturday, April 22, 2006

下雨的天气

我曾是很讨厌下雨的,也许是讨厌那湿碌碌的地,又或是讨厌那阴沉沉的天.从来不觉得下雨的天气有什么好意境.今天早上起来,窗外浠浠沥沥地下起了雨.我很有兴致地架起了三角架,用新买的相机照了几张相.

外面一片的绿意盎然,在雨中更是显得新鲜.原来所谓的意境不只是环境,更多的还是心境.现在是星期六的早上,外面的天气都不那么重要了.

Tuesday, April 18, 2006

-17 != 0xef.

Sometimes we omit the very basic. This morning, I was looking at this code:

char c1, c2, c3;
....
if (c1== 0xef && c2== 0xbb && c3== 0xbf)
{...}

I was reading a file, checking the first three bytes and verifing whether the file is a UTF-8 encoding file with signature. In the watch pane of Visual Studio, I saw the value of c1 was 0xef, value of c2 was 0xbb and value of c3 was 0xbf. But the if statement returned me false. It turns out that c1, c2 and c3 are all char type, which has a range of -128 ~ 127. Even if c1 == -17 and -17 has the same bit string, 11101111, as 0xef, c1 != 0xef. When I changed c1, c2 and c3 to be type of unsigned char or BYTE, which have a range of 0 ~ 255, everything worked fine.

Friday, April 14, 2006

郎朗的独奏会

星期四的晚上,我们去看了郎朗的独奏会.因为前两个星期刚看了李云迪的,所以看之前是抱着去比较比较的心态.毕竟这两人是目前在世界上最出名的中国钢琴家.到了现场,根据满座的程度可以看出郎朗在美国的名气要比李云迪响一些.大使夫妇也到场了.



以前在中国文化节的时候看过郎朗的演奏,所以他大幅度的动作倒不是很让我们惊讶.在春节联欢晚会表演的时候,他可是文静许多.春晚的时候,毕竟全国有那么多大爷大妈在瞅着电视看他.



整场演出看完还是相当满意的.他和李云迪的风格不同.我时常觉得他是在做指挥,身体的动作相当entertaining.有几段高潮的时候,他就象是在砸琴一般,难怪有人觉得他把钢琴弹得太随便.相比之下,李云迪弹得就很谨慎.我倒不觉得谁更好,一个是泰国炒饭,一个是糯米鸡,吃起来各有各的味道.有趣的是演出后签名时候的一个小插曲.排到我们的时候,前面的美国老太太和老公公希望郎朗给他们写点特殊的,因为是他们两人结婚五十周年纪念.郎朗忙说:"happy wedding day".也许是他忙昏了吧,anniversary楞是给他说成了wedding day.接着他一边给老头老太签名,一边跟旁边一人嚷道:"嘿,肚子饿了,咱们一会儿去哪儿吃点东西行不,叫上那谁."演出了两个小时,肚子饿了也是正常的.只是看着他一边鬼画符一样地在老头老太的CD上随便划着,一边操着东北腔大声嚷着一会儿要去吃饭,顿时没了艺术家的风范.也许在他的理解艺术就应该是通俗的,又或是下了舞台他就不再是那个艺术家郎朗了.想起李云迪签名时候小心翼翼的样子,觉得郎朗真是个很逗的人.

Programming contest. Interesting.

I read a news on CNET.com about international college programming contest. Surprisingly, only one US school (MIT) is in the top 10. Hmm, maybe schools like CMU didn't attend the contest. Anyway, the contest problems remind me of the old days in college when programming is all about solving hypothetical problems. I think sponsoring such a competetion is good for building up company image. It's not necessary a college competition but a competition open to the public. Macromedia holds this kind of competitions once in a while. If we are releasing Boxely to the public, just a hypothesis ;), a competition is one thing we can do to promote it.

Tuesday, April 11, 2006

Google Earth may be used for many things.

For example, promoting magazine. If the movie Cast Away were shot today, the director may have the rescue team locate Tom Hanks on Google Earth.

Monday, April 10, 2006

Is leaking OK? Maybe it is.

As all, especially C/C++, programmers know, leaking is bad. It is more than bad. It is evil. But leaking seems to be OK out of the programming arena. As president Bush explaining why leaking was OK, I saw news program discussing whether the US was going to bomb nuclear facilities in Iran. The program even showed a movie clip of the facility that might be bombed. Well, if this is not leaking intelligence data, then the news program is fooling us with a clip shot in someone's backyard. What are those editors thinking? At least they should postpone the program until 12:30 and let Conan report it.

Saturday, April 08, 2006

The "we sell it on ebay" store.

When I was having dinner at one of my favorite Chinese restaurants in Falls Church, Jasmine Garden, I saw a sign on the store next door, "We sell it on ebay". And then I realized that is the name of the store. The store is providing service to sell items for people on ebay. People can dump their used items into this store like throwing out trash, and they get money back later when their items are sold. Well, it sounds like a very good deal. But I just can't believe there are enough lazy people out there making this business profitable. Someday I may be able to carry dishes to a store after dinner and let them wash it for me. Maybe that store is there already, but "not evenly distributed" yet. :)

Wednesday, April 05, 2006

It is time to have a new name.

Corey told me that he's going to call me "keke" in order to differentiate my name "ke" from "key". He has been using "key" a lot in his everyday conversation lately as he works on the new databinding stuff. And I responsed to him several times when he was actually talking to Veronica about "key". Then I realize things can be worse if Don Box is working with us. When we took the coffee break, I learned that middle name is not neccesary inherited from parents. So I started to think about the middle name of my future child(ren), and also a middle name for myself. Spring is the season for new stuff, for example, new names. America Online Inc. just becomes AOL LLC, and I might soon become Ke Franken Ning.

Saturday, April 01, 2006

What a great pianist!

I just went to a piano recital of Yundi Li in Strathrmore Music Center last night. I didn't notice there is a music center there before. It is located on 355 in MD, very closed to the belt way and 270. The concert hall is smaller that those in Kennedy Center, but it is of a good size for piano recital. The concert was phenomenal. Li is a great pianist. After he won the International Frederick Chopin Piano Competition in 2000, he is getting lots of attentions not only in China but around the world. I remember he was in a Nike commercial once. Yes, a pianist in a Nike commercial. Li looks much more handsome than he does in photos. Unfortunately, I forgot to take my camera. This is not just my opinion but from my fiancee and her lady friend. We all agreed that Li needs to hire a better photograhers. And he also needs a host. He didn't speak at all but played and smilied because he doesn't know much English. And he looks like an introvert. He does have a very good smile though. The whole concert was not very interactive. It would have been a better concert if there is a host who can introduce Li a little bit and what is he going to play. A pretty lady host is even better. However, he is so good at playing piano that we don't care much about anything else. He stunned the audiences with his skill.

Beside Li, Lang lang is another Chinese pianist who is well-known here in the United States. Lang did not won any big competition like Li did, but he is more famous in the US than Li because he came to the US in 1997. He speaks English. And he is an extrovert. As a result, more people know him here and the ticket price of his concert is more expensive thatn Li's.