Saturday 31 March 2007

Review on "The Pragmatic Programmer"

Prelude:
Yeah!!! : ) Another job done for 2007!!! I finally finished reading the book "The Pragmatic Programmer" (after holding on to it for almost a year now! -.-" which I felt bad indeed!!!). But this doesn't mean that it is a bad book at all...in fact it is a very informative one (but only to programmers and programmers who 'cares' and 'want to become better')!


Brief Review and My Thoughts on the Book:
The book is definitely about how to become not just a 'good' but a 'professional' programmer! The book contains various tips and ideas on ways to make a programmers' life more efficient and prevention from tripping up in a software project.

It goes from talking about the general ways to improve coding; how to approach and begin a project; to expanding your software tools to make your programming life easier; testing of the software and user satisfaction.

Speaking from a SE (Software Engineer) grad point of view, a lot of the things mentioned in the book are already known & taught to us e.g. decoupling and cohesion of modules, testing should be done along side of coding. But after reading the book, I feel that it was able to emphasize these importance concepts to me, making it more 'believable' in practise.....encouraging their application in real life projects.

Notable Tips from the Book:
Some of the notable tips for me from the book (extracted and referencing from the book):
  • DRY - Don't Repeat Yourself
    "Every piece of knowledge must have a single, unambiguous, authorative representation within a system." Duplication should not arise not only in the code, documentation (code + technical), functionality of the system and even information and even 'interdeveloper' where the same function gets implemented in duplication.
  • Eliminate effects between unrelated things
    "We want to design components that are self-contained: independent and with a single, well-defined purpose. Then you know that you can change one without having to worry about the rest."
  • Fix the problem, Not the Blame
    "It doesn't really matter whether the bug is your fault or someone else's - it is still your problem and it still needs to be fixed."
  • Don't Panic When Debugging
    "Take a deep breath and think about what could be causing the bug."
  • You Can't Write Perfect Software
    "Software can't be perfect. Protect your code and users from the inevitable errors."
  • Configure, Don't Integrate
    "Implement technology choices for an application as configuration iptions, not through integration or engineering."
  • Separate Views from Models
    "Gain flexibility at low cost by designing your application in terms of models and views." This does not mean the MVC model from web development....the same concept can be applied to any application at its entirety...where the whole system support the concept of multiple views of the same data model, or common viewers on many different data models, or even multiple controllers to support various input mechanisms on the same view.
  • Don't Program by Coincidence
    "Rely only on reliable things. Beware of accidental complexity, and don't confuse a happy coincidence with a purposeful plan." i.e. don't program by 'fluke'! Understand why something happened in such a way!
  • Test Your Software, or Your Users Will
    "Test ruthlessly. Don't make your users find bugs for you."
  • Gently Exceed Your Users' Expectations
    "Come to understand your users' expectations, then deliver just that little bit more." But don't overdo it....as it may be so overdone that it does not match their original concepts.

Conclusions:
Overall the book does have a lot of recommendations and ideas on how a programmer can improve their programming life. Although at places I found it to be boring to read (probably because I read it right before my sleeping time! -.-"), but I think it is definitely beneficial for all programmers to who want to better themselves to read this book. I think the book would fit better as a reference book, where you take the book out for a read when you are 'lack of motivation'.

Wednesday 28 March 2007

YouTube 2006 Video Awards - Results

Have been quite busy recently at work as I tried to finish off my tasks for a sudden announced dead line!!! -.-" haha so (surprisingly enough) I have been really focussed at work and didn't even have time to take a look at what was going on around the world (i.e. what I actually mean is I haven't been reading my RSS feed)! : P But anyway.....it's all happy now.....so I thought it's about time I start relaxing again! : )

Which brings me to this.....I happened to come across the YouTube 2006 Video Award about a week ago on slashdot....which was still asking people to place their votes at the time. And today when I went to the site again...haha the winners are now all announced! (cool! just what I can use to relax myself!) : P

(If you haven't seen it) ENJOY!!!
YouTube 2006 Video Awards

P.S. - Watch the 'Kiwi' one...it's definitely so sad but so good at the same time!!! If you are a 'kiwi' you will def understand it! : ) Remember to "Have faith" and "Never Give Up"!!!

Wednesday 21 March 2007

歌曲分享: Endless Road

haha yes I am renaming the title to be "歌曲分享" as "歌曲回顧" seems to imply sharing of very very old songs.....which I don't necessary do.......as the song I would like to "分享" today was only released in 2004:

Endless Road - 主唱: 林俊傑
(作詞:林俊傑 作曲:林俊傑)

Personally, I found 第二天堂 to be the best JJ's album for me (to date). hehe May be this is because it is the first JJ album I listen to....and probably because I enjoy quite a few songs inside this album that I both love and can listen to for a long time e.g. 第二天堂, 豆漿油條, 江南...

However the first track in the album that caught my attention when I first listen to it was actually "Endless Road". It is the last track of the album and this is the English version of the song 害怕 (which is also featured in the middle of this album). I believe there are a lot of people who love the song 害怕, but for me the English version was the one that first attracted me and is still my preferred one! : P

Why? haha well I found that not only is the music nice but once again (I love the) AWESOME lyrics....the lyrics totally blends in with the mood of the music. Together with JJ's performance of the song....it really does convey the sadness that is hiding inside his heart and afraid of his loneliness and to face the truth of the break up. In particular I love these two verses:
A crystal forming in the eye
Maybe this would be the last
A winding path down my face
Till I begin to taste the bitterness inside


Why am I still holding back my tears
In this loneliness there's nothing to fear
Every chord still seems a wonder
How we could be together
Every time I ask if this would be the last
If you haven't really listen to the English version, then perhaps you may like to try it now (pay attention to the lyrics)!

Endless Road (just song) (hmm...think that link is broken, try this link)
Endless Road (mv from youtube....but song is of bad quality and the mv was actually taken from another song! -.-" Don't recommend as the mv ruins the 'feel' for the song...but if you want something to look at while listening then click this!)
害怕 (If you still prefer/want to watch the Mandarin version of the song from youtube)

P.S. - Apparently JJ wrote the lyrics of this song for 他以前既女朋友! haha so it is true that you have to have 'experience' before you can write something so touching! (both lyrics and the music wor!!! 勁呀!!! : O)
(see source which also has the full lyrics for both 害怕 and Endless Road)
P.P.S. - His hair back then in 2004 was definitely way better! ><"

Monday 19 March 2007

Pad Thai for a Work Day Lunch (Yippy)!!!

mwhaah today (due to some effects of S.T.M.L and M.D.), I had to go into Pakuranga to return and to obtain some 'goods' from a 'special person'! :P hehe
(p.s. and I'm laughing about this hehehe!!!)

Anyway so I was 'honoured' to be invited into the Eastern area for lunch and in particular to try out this restaurant "Thai Family Restaurant" in The Plaza (Dineout reivew).

For our entree, we each had a delicious, freshly made spring roll and a lovely chicken satay which was covered by grounded peanut sauce (hence the sauce was strong enough to be just right). Each of the spring roll and the chicken satay costed $1.70 each. So it was definitely real good for us as we can try some entree as well as a main dish!!!

(Unfortunately we forgot to take the photo of the dish beforehand....hehe so photos of the 'end' to show how delicious the food were! : P)

As for our main we shared a dish of Pad Thai. The tastes was nice and authentic! The balance of the sweetness and the sourness was just right....but the portion was just a bit small (but may be because I can never get enough of Pad Thai!!! eheh). The cost for all mains are $9.90, which is the same as East. Hmm haha I don't think I can decide between the two!!! ><" This is definitely authentic, while East is haha 'East' lor.....and their dish is bigger! So to be greedy I wouldn't mind having both of them! :P (The good thing is they both uses peanuts and provides a slice of lemon...which I reckon is essential to a good plate of Pad Thai!!!) :P
(A photo of the shop's name and logo on the front of their menu)

In summary, I thoroughly enjoyed the lunch (esp on a Monday...the start of another week of work -.-)! Thanks to the 'special person' (cough cough! j/k j/k : P) who introduced and invited me to this Thai restaurant. This restaurant is definitely in my 'to be back' list! : )

*P.S. - One thing I definitely want to try is their "Prawn Cakes"!!! I love eating prawn cakes and it is hard to find good prawn cakes in NZ! Looking forward to try their prawn cakes next time!!! : O

Thursday 15 March 2007

Quote to Share: 陶喆 (from 就是愛你演唱會)

在生命當中,什麼事情,
只要有夢想,只要有信心,
就可以做得到,
One finger cannot stop it!
陶喆 @ 2006 就是愛你音樂驚奇之旅世界巡迴演唱會

Tuesday 13 March 2007

A (Poem !?) Piece of Text Created at Work

While I was at work today....even though it's a Tuesday.....it just doesn't feel right and I have no idea why! ><" hmm....probably because I'm stuck indoor at work and knowing that I got a speech to prepare for and looking out the window..the sky was just so GREY!

It is interesting how sometimes the weather affect on our mood and our feelings!!! : O

Anyway, haha during a conversation with my friend (at work! : P hohoho)....I wrote the following....haha and apparently it sounded like a poem to her! haha wow...that made me happy! : P
me feel boreeddd!
me feel sad!!!!!!!!
the weather makes me grey!!!!!!! ><"
An expression of my boredom and my feeling of greyness during work,
LemonTz

Friday 9 March 2007

Dummy 101: DIY Ext HDD - Tip #1: Formatting the Drive

So it is my first time putting together my very own external HDD!!! It was a wonderful and excited 2.5 hours journey filled with surprises!!! : P And everything worked in the end! Yeah!

So once you have assembled the HDD and the case together, you plug in the USB, and you see nothing! You went to 'My Computer' and see no drives! What's wrong??? It is very likely that your HDD is not formatted and hence WinXP will not be able to understand/recognise its content (since it's not in a particular file system format). In this case you will need to format your drive first!

Formatting you HDD:
You may use any tools you like to format your hard drive. If you are unsure...ask your friend, Google! : )

For me, I've asked my friend to format the drive for me via Disk Utility which is available on Mac, formatting the drive to MSDos format. I was also successful in using Partition Magic (for Windows) to format my drive!

What happens if your drive doesn't seem to be recognised by WinXP?
At the least, no matter if you have formatted or not formatted your drive or not....WinXP should be able to recognise the newly attached USB hardware! If you can't see the drives on 'My Computer', check the following:
  1. The little attached hardware icon is shown in the notification area

  2. Go to 'Device Manager', select disk drives, and then go to the furtherest right button on the toolbar which will allow you to 'Scan for hardware changes' (see pic below).


    After your refresh, if there's nothing wrong with your hard drive, you should be able to see the attached external HDD (as seen in the pic).

  3. (If you use Partition Manager) After you have done step 2, you should be able to see your external HDD as another 'disk'. Then you can partition your HDD in the usual way from here on! : )
*P.S. - Of course thanks and appreciations must go out to my friends who had given me advise in buying the HDD and those 'friends who got my awesome ( hehe j/k) looking case for me....and of course to that 'friend' who convinced and helped me to put together my very FIRST ext HDD!!! : )

Thursday 8 March 2007

Redesiging the Mobile Phone Layout

One day at work I read this article which was introduced by an article from my slashdot feed (if you haven't read it yet):

Mobile phone layout
(Source from this page)
"The conventional mobile phone design has the keypad positioned below the LCD display screen. This orientation provides the user a clear view of the screen while a text message is being typed by using the thumb of the hand holding the mobile."

It argues that typing text messages is less awkward this way and you can basically just let you thumb do the 'walking' and your palm will be holding on to the body of the mobile more 'stably' and 'safely'.

My Thoughts:
haha first of all marks go for the person for 'redesigning' the mobile to make it more ergonomic. But ahah wow....it's really not 'redesigning' at all, is it!? And they are actually filing a patent for it!!! : O

But then who am I to talk about creativity but I do appreciate their thoughts for the users of the mobile! haha really I would never thought that the mobile can be much more comfortable to use by holding it 'up-side-down'!!! This kinds of opened up my mind a bit! haha May be we should all try to use our mobile up-side-down just to help them to test their to-be patented design! ahah : P

p.s. - I reckon I'll just feel weird using it up-side-down...as I've gotten use to our conventional mobile! Oh.....and I just thought of why the LCD is placed at the top of our screen...because from UI design...people read from top-to-bottom ah ma!!!! : P (hehe the good old HCI!)

Monday 5 March 2007

歌曲回顧: 我的爸爸媽媽

最近真的多了一些「害怕」, 也許我真的還是大不了! 哈哈......

就這樣令我想起幾年前 Twins 的一首歌, 歌詞曾經令我非常有共鳴. 哈哈,佑唔到現在也是! ><"
歌詞很簡單, 可能你也會找到一些共鳴吧!

2003年, in the album 'Touch of Love', 鐘欣桐(阿嬌)主唱, 歌名 「我的爸爸媽媽
(for ktv version on youtube click here):
從前曾習慣 不停叫「爸爸 媽媽」
一個人倦了 總想到家
何時又再坐再臂內 抱我飲茶
原來大個了 要很高代價

為何還做我的媽媽 如老友好嗎
請顧問細訴我 要怎麼找到她
捱世界 好玩嗎 人情世故 凶險吧
求你告訴我 不算可怕

世面寧願不了解 留在這家中最大
往日年紀很細 最要關懷
有怪莫怪 只怪
我已踏進 大人的世界 Ha...

Sunday 4 March 2007

LemonTz on the 'Run'

Prolog:
Recently I have been picking up running again as I tried to keep myself trained up for the upcoming RTB (Round the Bays) event. (haha so I won't get too exhausted after the event with extreme muscles pain!!!)

hahah and I should say thanks to my friends...who initiated the 'training' idea...now I am able to keep to my 'weekly' training! : P

I must also say that picking up running again have really bring back memories of my 'good old' badminton days and the college days. You see 'Running' has really bring back my focus again. You may be wondering 'huh!?' to what I mean...so let me use this blog to share with you! : ) (And some of my own tips in running long distance!)


P.S. - I am a long distance runner! Unfortunately I don't have the 'burst' to run short distance. So in here when I say running....I am particularly referring to LONG DISTANCE running! : )

What running means to me?
Okies....haah running does not really have any special meaning to me! But what it does is that it does make a positive impact to my life. Okies, may be not my whole life...but at least I feel GREAT after a run.

To me, running is pretty much a 'concentration training exercise'. You need to focus on your pace, your breath and most importantly your mind!

Keeping yourself running:
Usually when I go out for a run, I would start off with a pace I am comfortable with. Some of you may think that 'running seems boring...you just go out and run, run, run...for no reason at all'!!! Well I actually find running will help me to do things MORE EFFICENTLY!!! This is the part I would like to share! : )

I usually go out and do the jogging by myself and I don't listen to any music at all. I start off by picking a pace I am comfortable with and once I am settled down, various thoughts will just flow into my mind.

Usually I would think about what I need to do when I get back home; what I need to do for the rest of the week; or how do I do this and that; how do I solve a problem...various things which I didn't have time to think about/ignored during the week will just flow into my mind. I guess this is also because when you are running by yourself, you feel you are creating some personal space for yourself! For me, thoughts and ideas just flow into me very easily!

Before you know it, after you have finished with a thought, you would have found yourself already ran a few hundreds of metres already!!! You won't realised how long you have run....which may 'scare' some people when they have to think about how much 'further' they have to run! Once you have gone through a few thoughts/ideas, you would have found yourself already ran some good hundreds of metres already!!! : )


Running towards the finish line:
So after a few more thoughts...you would realise that THOUGHTS will just stop coming into you (even though you may still have a lot more things to think about). Why? This is because you are starting to feel TIRED!!! i.e. the point where the realisation of 'tiredness' is starting to make you feel the 'PAIN'! The point where you may feel your muscles is starting to ache or when you feel you are starting to breath in deeper, calling for more oxygen.

This is where more 'concentration exercise' comes in!!! In order to push myself to continue running...I would find an object that is within reasonable distance and set it as my target. For example, a lamp post; a tree; a structure...anything that you can set sight to. Once you have identified your target.....it'll be your 'temporary' finish line.....and you just 'GO FOR IT' and run towards that finish line.

It is very important to NOT to start increasing your speed/pace just because you are aiming towards the TEMPORARY finish line!!! Make sure you keep AT THE SAME PACE....and remember to draw in the OXYGEN deeply as you breath...keeping it at the SAME PACE too!

Once you reach your temporary finish line...you may feel a 'moment' of satisfaction! Or at least a moment of comfort/joy! : P But remember 'don't slack'...CONTINUE MOVING and CONTINUE RUNNING....and identify your NEXT TARGET...and 'JUST GO FOR IT' again! (using to the same technique that you used before for your last temporary finish line!!!) Eventually....you will reach the REAL & FINAL finishing line! Touching the HOME BASE! : )


A Quick Guide of My Tips on Running:
  • Remember to always set some aims for yourself before a run.
    E.g. To run the whole way; To take two short breaks only during the run
  • Set up your route, know your route and PICK the finishing line.
    E.g. I will run to the golf course and back, the golf course is the 1/2 way mark and running back towards my house which will be my finish line.
  • Remember to WARM UP before your run!!!
  • Start your run by running at a pace you are comfortable with. Remember not to set a pace that is too fast....because.... (see the next bulleted point)
  • Keep to your pace! Remember to keep to your pace!!! You are not allowed to slowed down (as this will easily make you wanting to stop very early before reaching the finish line)!!!
  • When you are starting to feel tired. Find a 'temporary' finish line....and just AIM FOR IT and GO FOR IT. Don't be lazy....don't stop until you reach your finish line!!! : )
  • Once you reach your temp finish line....DON'T STOP.....KEEP MOVING.....and identify your NEXT finish line!
  • Try not to 'sprint' towards the temp finish line....as you may found yourself too TIRED to run towards your NEXT finish line. Giving yourself excuses! But feel free to sprint towards the REAL FINISH LINE though!!! : P
  • HOWEVER at anytime....be REASONABLE!!! If you are starting to have strong stitches, pain in your chest, dizziness or injuries....PLEASE slow down and stop and REST!!! You can always push yourself further next time!

Conclusions of my thoughts on running:
Wow....if you happened to get to 'here' of my blog. Wow...I must say THANKS!!! I just realise how LONG this blog is! ><" haha sorry I guess I just really wanted to share my thoughts on running. I'm not sure if you agree with me or not...but this is just what I do and my own thought when I go out for that occasional jog! : P

I guess I just feel really great when I am able to think through things during my run. As I am able to organise/sort out things in my life or to free up some questions/problems/tasks, making decisions.....basically after my run....I would find my brain is free of troubles and myself more motivated to do the things I want/need to do! : )

Not only this....but during running when I found myself needing to push myself to the finish line, the opportunity to use my concentration just somehow makes me more 'focus'. It just indirectly helped me to become more 'focus' in life (at least for the day hehe) and to have a stronger stamina and determination! All in all, after a run....I just feel 'GREAT' mentally....haha but probably not physically ahaah! But it's all worth it! : )

P.S.
- I actually thought of writing this blog during one of my run!!! I just thought to myself...I must write something about my own thought on running and my own tips when running!
P.P.S. - To any 'professional' runners out there....you may not agree with my tips or may think they are incorrect!!! hehe but yeah just a warning this is just my own personal thoughts and tips on long distance running. Just a warning here!
P.P.P.S. - (Just an extra bit! : P) I remember when I tried to train my stamina for badminton during the 'college' days. I still remember going for a run during my 5th form exam break. And it really does help me in motivating my studies and most of all in 'solving' problems...as when I go for my run....thoughts of things I don't understand during my study will just pop into my head for me to think about. In addition it keeps you healthier as well esp during the exam study period! ahah may be you can call me a geek... ><" but it did helped me to get through my studying! : )