November 8, 2005

Screenrc - window title

hardstatus string "[screen %n%?: %t%?] %h"

November 6, 2005

My screenrc file

# kill startup message
startup_message off

# detach on hangup
autodetach on

# define a bigger scrollback, default is 100 lines
defscrollback 1024

# shell
shell -bash

# An alternative hardstatus to display a bar at the bottom listing the
# windownames and highlighting the current windowname in blue.
hardstatus on
hardstatus alwayslastline
hardstatus string "%{.rW}%w %{.bW}%m/%d %C%a"

September 7, 2005

Can't beat the Big Ben. It is so magnificent.

Close-up of the Tower Bridge

Do you see the castle? or you just see the "Bullet" building?

A warning sign with English-style humor

The famous London Tower Bridge

Saint Paul's Cathedral, taken from the tour bus

Big Ben and the Parliament Building. The river is River Thames

People watching changing guard. Polices try to maintain the order.

Changing Guards, every day around 11:00am.

London Police(Lady)

The Guards of the Palace

London Eye. Each "room" can have up to 25 people. On Valentine's day, it costs about $700 for two people!

Big Ben, one of the symbolic buildings of London

Lovely English House in front of the Buckingham Palace

Buckingham Palace, where the Queen of England lives.

Old Pals, with Churchill and Roosevelt

Tiny cars are popular in London. It must be very easy to park. :-)

White Swan at Hyde Park, London. It likes to show off its beautiful feather, like a little girl showing off her pretty skirt.
London's phone booth. With a calling card, I called home from it.

August 26, 2005

AWK sort array

GAWK provides asort and asorti functions to sort arrays, but it is not useful in sorting arraying while wanting to keep the relationship between the index and the value. Here are two functions, zsort and zsorti, that do this.

Here is the code

#!/bin/gawk -f
function zsort(a,b){
delete b;
sort= "LC_ALL=C sort -k2nr -t,"
for (i in a){
printf("%s,%s\n",i,a[i]) |& sort;
close(sort, "to")
while ((sort |& getline line) > 0){
return count;
function zsorti(a,b){
count =0;
delete b;
sort= "LC_ALL=C sort -k1nr -t,"
for (i in a){
printf("%s,%s\n",i,a[i]) |& sort;
close(sort, "to")
while ((sort |& getline line) > 0){
return count;
a["x"]=5; a["y"]=7; a["z"]=6; a["a"]=10;

# sort by the array value
for (i=1;i<=num;i++){
print "==============="
# sort by the array index
for (i=1;i<=num;i++){

Here is the result:


August 22, 2005


Cherry Blossom of 2005 Posted by Picasa

WordAloud released to sourceforge

I recently created my first open source project: WordAloud. It pronouces an English word and displays its definition. I find it very handy. I hope people will use it.

August 13, 2005

What is True Leadership

This is directly from the book by Suzanne Bates.

Here is the leadership value system articulated by our 293 respondents, in roughly descending order:

  • Integrity. .Responses in this category referred to both business dealings and personal interactions. The words most frequently used by respondents to frame this concept were honesty, integrity,ethics, fairness, candor,sincerity, trustworthiness, and truthfulness .
  • Vision.
  • Listening.
  • Giving feedback. Participants place a priority on giving credit where credit is due, including public praise for a job well done. They cited offering positive feedback when deserved and valuing employees' contributions.
  • Emotional intelligence. Treating people well and having empathy and compassionate highly rated.
  • Communication skills.
  • Knowledge and intelligence.
  • Managerial skills.
  • Follow-through ... Strong leaders are consistently concerned about how things come out, not just how they begin
  • Humility. An authentic leader is humble -- willing to seek information and advice and to admit mistakes when they occur.
  • June 26, 2005

    Debate about who founded Chrisitianity

    Recently, I got very interested in Qur'an. I want to compare it with Christianity. I found some very good articles: Who Founded Christianity - Jesus or St. Paul?

    June 21, 2005

    Some athlete stories

    Have you ever heard of:
    John Landy

    How about:
    Roger Bannister

    On May 6, 1954, Roger Bannister became the first man in history to run a mile in less than 4 minutes. Within 2 months, John Landy eclipsed the record by 1.4 seconds. On August 7 1954, the two met together for a historic race. As they moved into the last lap, Landy held the lead. It looked as if he would win, but as he neared the finish he was haunted by the question, "Where is Bannister?" As he turned to look, Bannister took the lead. Landy later told a Time magazine reporter, "If I hadn't looked back, I would have won!"

    The Armstrong story

    The Tour De France, is a 2,126 mile bicycle race through the country of France, conducted in twenty stages over a period of three weeks, an average of over a hundred miles a day. Just for comparison, that's about the same as riding a bicycle from Morgantown, WV all the way to Miami, Florida, and then back again. The race includes a bit of everything: all-out sprints; long days traveling through the French countryside; agonizing climbs over the Pyrenees mountains; and then terrifying descents from those same mountains, in which the cyclists reach speeds of over 70 miles an hour. The athletes have to contend with all kinds of hazards: narrow streets, blown tires - even small children darting out into the road. And they ride in all kinds of conditions: heat, wind, rain, even hail. In short, it is one of the most grueling athletic contests ever devised by man.

    Lance Armstrong's single-minded devotion to training; his willingness to suffer physically, to push his mind and body to their absolute limit, in the pursuit of athletic victory. That's really been the key to his success. Listen to this passage, which describes his preparations for the 1999 Tour De France:

    "I went back to training. I rode, and I rode, and I rode. I rode like I had never ridden, punishing my body up and down every hill I could find. . . . I remember one day in particular, May 3, a raw European spring day, biting cold. I steered my bike into the Alps, with Johan following in a car. By now it was sleeting and 32 degrees. I didn't care. We stood at the roadside and looked at the view and the weather, and Johan suggested that we skip it. I said, "No. Let's do it." I rode for seven straight hours, alone. To win the Tour I had to be willing to ride when no one else would ride." - It's Not About the Bike, pp. 221-222

    Riding a bicycle up a mountain, alone, in the freezing rain, for seven straight hours, is commitment. Lance was willing to undergo any amount of suffering, any amount of physical and mental punishment, in order to win a bike race.

    Sometimes you have to run the race alone but don't give up.

    Fruit Dinner

    This is the dinner we had today:

    1 bag of green salad
    2 Mangoes
    4 Lemons (extracted juice)
    6 Patatoes
    12 Carrots ( extracted juice)

    That's a interesting dinner, is it?

    June 16, 2005

    InfoWorld 2005 Compensation Survey

    Regional Rewards:

    San Francisco/San Jose: $169K
    Boston: $150K
    Orlando: $146K
    New York: $142K
    Atlanta: $113K
    Raleigh/Durham/Charlotte: $97K
    Chicago: $92K
    Dallas/Fort Worth: $91K