For last few days I am hooked up in the classical Programming Pearls. It's an amazing read. The author makes you feel programming so easy. Just now I have finished column 7 titled as The Back of the Envelope. After learning about various back of the envelope techniques given by the author I was reminded some of my estimations, where it reflected my sheer intelligence, really! After some hesitation, I was able to convince myself that it's okay to express some of my dumbness to the world. So here I go, bear with me.
Most embarrassing was while estimating how far is Kolkata from Chennai. I don't know exactly how I came up with the figure of 600 km! Later when I booked my ticket to my home town, I found the distance is 1662 km. OMG! It's almost 3 times than what I thought! And now after reading the book I apply the techniques, which makes lot more sense. On average Chennai Mail travels around 30 hours to reach Kolkata with average speed of 50 km, which makes the distance 1500 km. Lot better in deed, but [sigh...] too late. Another one happened in a beautiful night when, after a good dinner, I thought it'll be wonderful to spend some time in Besant Nagar beach beside the sea under the dreamy light of moon. I asked my friend let us go. He wondered and asked how far is it? [He was new in Chennai, that time] I was pretty convinced that it can't take more than 15 minutes. My calculation was... We walk 1 km/ 7 mins and Beach is hardly 2 km away from our room. To my wonder when we saw the water of Bay of Bengal, we had already walked for 40 mins. Okay I don't dare to find any excuse behind this, may be both of my assumptions (speed and distance) went terribly wrong :(. Yet on another occasion I turned out to be too dumb in this estimation business. While starting coding for our product my boss asked me "So sahid, what do you think? How much time will it take to finish this?" May be being over-enthusiastic, my confident response was "It should be complete within 4 months". And to my wonder it took more than a year for us to shape up our HRWorks.
If I dig deep may be some more will come out, but I don't really want to let that happen. In between why don't you try to estimate how much water flows out of the Ganga (if not Mississippi) per day. Don't expect me to guess. I've just finished the column. Answer is on my lip, "As much as flows in".
Thursday, August 03, 2006
Monday, July 03, 2006
Looking back at my identity...
Today was a bad day for me. I got a call from one of my childhood friend. Not from him actually, but from his mobile. Strangely the caller was a police from our local police station inquiring some details. He had been shot to death yesterday night while illegally supplying cattles to neghourhood country, Bangladesh! No doubt, he was doing crime. But I feel sad for this whole incidence. Few days back when he called me, I didn't talk to him giving excuse of my busy schedule. Thought of calling him later. But I'm too late. This whole thing has made me feel sorry for myself, for my beautiful village, my wonderful early days friends. If my father wouldn't have been bit richer who knows I could also have similar fate. Many of my early friends are literally struggling to survive, few doing crime by illegally supplying Indian goods to Bangladesh, few serving foods in restaurants, few cooking in hotels, few plowing in firm lands... and here I'm expressing myself in Internet! I feel really odd when I go back to my village. Why this much contrast? Had they got enough opportunities, couldn't they have been leading a better life? No one is there perhaps to listen. We can only expect tomorrow world will be a better place.
Let Allah bless his soul. Amen.
Let Allah bless his soul. Amen.
Sunday, June 11, 2006
When programming is not fun
Last Monday I completed my first year of my employment. My boss asked me how did it all go? How much you enjoyed the work, if you leave the money part? I replied I enjoyed 40% of my work. So what about rest 60%? Well, those were all just work, neither fun nor I enjoyed. That made me thinking why it was not all fun doing coding? My reasoning is you don't code always, you get to do other things also to make your code work, to make it part of a salable product. Here are some of the most boring things I came across while programming..
Most boring and time sucking thing is bug fixing. Wise man says Bug fixing is never fun, it's just work. I totally agree with that. But while fixing bug I try to motivate myself by looking at other side of the coin. If I write a piece of code, it's my responsibility to make it work. This sense of responsibility greatly reduces the sense of boredom, at least for me. But debugging code written by others can never be fun, particularly if the code is not readable, not indented and not documented well.
Another irritating thing is change of specification. Earlier I quoted Computer programmer creates their own world! But real world is bit more real perhaps. A programmer's ultimate aim is to see his program being used by others. But others don't only use it they also give feedback. Accordingly you need to add more features and that leads to my first observation as each new feature introduces a new bug. And also often you need to change in fundamental specification depending on the user reaction. That is really painful. Irony is - no longer you yourself are the creator of your world, but you are creating a world in collaboration with your users. Democracy is not always good I guess!
One of the great philosophy of Java is write once reuse every where. But reuse of a third party tool often leads to a pathetic situation. You write your code using some third party tool assuming some particular behavior. After that you found your code doesn't work. Some digging reveals the third party tool doesn't work as you expected. Some time you can argue that my misunderstanding created problem for me. But what if I really find a bug in that tool? (what is often the case). Why should I suffer for other's bad program?
One more, but may not be the last, cause of irritation comes when you take over some other programmer's code. If it's not written well, It's damn damn painful to figure out what's happening there.
May be there are some more situation when programming can't be fun. But these are the things came into my mind..
Most boring and time sucking thing is bug fixing. Wise man says Bug fixing is never fun, it's just work. I totally agree with that. But while fixing bug I try to motivate myself by looking at other side of the coin. If I write a piece of code, it's my responsibility to make it work. This sense of responsibility greatly reduces the sense of boredom, at least for me. But debugging code written by others can never be fun, particularly if the code is not readable, not indented and not documented well.
Another irritating thing is change of specification. Earlier I quoted Computer programmer creates their own world! But real world is bit more real perhaps. A programmer's ultimate aim is to see his program being used by others. But others don't only use it they also give feedback. Accordingly you need to add more features and that leads to my first observation as each new feature introduces a new bug. And also often you need to change in fundamental specification depending on the user reaction. That is really painful. Irony is - no longer you yourself are the creator of your world, but you are creating a world in collaboration with your users. Democracy is not always good I guess!
One of the great philosophy of Java is write once reuse every where. But reuse of a third party tool often leads to a pathetic situation. You write your code using some third party tool assuming some particular behavior. After that you found your code doesn't work. Some digging reveals the third party tool doesn't work as you expected. Some time you can argue that my misunderstanding created problem for me. But what if I really find a bug in that tool? (what is often the case). Why should I suffer for other's bad program?
One more, but may not be the last, cause of irritation comes when you take over some other programmer's code. If it's not written well, It's damn damn painful to figure out what's happening there.
May be there are some more situation when programming can't be fun. But these are the things came into my mind..
Thursday, May 18, 2006
What does the Grand Father say?
Just now I've read this article [Stanford Magazine] on Don Knuth. And it makes me feeling guilty. If you are aware of my previous post, there I was trying to say why Programming is fun. And no where I didn't even mention about the great Prophet. Oh! God of Computer Science please forgive me.
If you didn't read that article read it, it gives some more insight why Computer Programming is an art and that too in Prophets view.
If you didn't read that article read it, it gives some more insight why Computer Programming is an art and that too in Prophets view.
Monday, May 08, 2006
I like programming
This is a topic very close to my heart indeed. Let me try to find out why i like programming..
First of all programming gives me money. Right now I'm working as a S/W developer in a start-up called appscale in Chennai. Though it doesn't pay me like some IT giants pay to its employees, but I'm more than happy with my pay-package. I still remember the day when I first received my pay-check from my boss. It's indeed a good feeling to earn money doing what I love.
And perhaps programming is the only useful thing I've learned in my short span of life. It was not a very well-thought decision to take Comp-Science as Hons subject in my BScs. It was kind of gamble. When I joined my BSc course (i.e 2000), studying Computer-Science used to be considered as an uncertain and suspicious idea in our place, particularly as an Honours subject. Joining some stupid Engineering college and spoiling your career (I've really a hateful grudge over Engineering colleges, may be I'll write on that some
time) was appreciated better. But the gamble (or whatever) worked for me. I didn't get lost at least. I thank my fortune!
As a school-kid I always hated abstract topics like philosophy and all. But In my very first college day I learned a new mantra from my teacher "Programming is a philosophy". I couldn't appreciate what did that mean! Mind it I never touched a key-board before that. I still remember a guy proudly showing me a trade mark Microft (don't ask me to correct the spelling, i like the pun) blue Editor Screen in MSDos and telling me with kind of bullying attitude "hey moron! see it's called notepad, here you can write your stuffs". I don't exactly remember how I reacted that day. Over all my acquaintance with Computer-Science was never exciting. But slowly it started rolling. First time in my life I started enjoying doing home-task, writing pseudo code for the programs which we had to code in college-lab. In the process slowly I was realising what that *philosophy* is. What I like most of programming is you don't need to have a great theoretical background to start writing good quality code. Important is figuring out the problem and applying yourself. In the process of applying automatically you learn many things which you didn't know earlier. Of course to write really path-breaking program you need to be extra-ordinary. That is true for every field isn't it? After all not every budhiya runs 65 Km at his age. There are not many Linus Torvalds, RMS or Bill Joy! I wish I had that mathematical back-ground to write an evolutionary search-engine. Recently I was reading a book by no one but Linus Torvals, where I found most beautiful explanation of this philosophy -
I'm personally convinced that computer science has a lot in common with physics. Both are about how the worlds at a rather fundamental level. The difference, of course, is that while in physics you are supposed to figure out how the world is made up, in computer science you create the world. Within the confines of the computer, you're the creator. You get to ultimately control everything that happens. If you're good enough, you can be God. On a small scale.
I was truly moved reading this. And thing is I no more hate philosophy as a subject. It's really nice feeling to make the dumb machine work as you want. It gives you lot of pleasure. I just can't stop quoting from another classic "The Mythical Man-Month" by Brooks -
Oho! before signing off let me give a disclaimer. I never claimed to be a geek. I'm an average programmer with bit of passion for learning new things and writing better code. And betterment continues everyday. I dream of the day when I'll be able to write "good code, beautiful code, excellent code".
First of all programming gives me money. Right now I'm working as a S/W developer in a start-up called appscale in Chennai. Though it doesn't pay me like some IT giants pay to its employees, but I'm more than happy with my pay-package. I still remember the day when I first received my pay-check from my boss. It's indeed a good feeling to earn money doing what I love.
And perhaps programming is the only useful thing I've learned in my short span of life. It was not a very well-thought decision to take Comp-Science as Hons subject in my BScs. It was kind of gamble. When I joined my BSc course (i.e 2000), studying Computer-Science used to be considered as an uncertain and suspicious idea in our place, particularly as an Honours subject. Joining some stupid Engineering college and spoiling your career (I've really a hateful grudge over Engineering colleges, may be I'll write on that some
time) was appreciated better. But the gamble (or whatever) worked for me. I didn't get lost at least. I thank my fortune!
As a school-kid I always hated abstract topics like philosophy and all. But In my very first college day I learned a new mantra from my teacher "Programming is a philosophy". I couldn't appreciate what did that mean! Mind it I never touched a key-board before that. I still remember a guy proudly showing me a trade mark Microft (don't ask me to correct the spelling, i like the pun) blue Editor Screen in MSDos and telling me with kind of bullying attitude "hey moron! see it's called notepad, here you can write your stuffs". I don't exactly remember how I reacted that day. Over all my acquaintance with Computer-Science was never exciting. But slowly it started rolling. First time in my life I started enjoying doing home-task, writing pseudo code for the programs which we had to code in college-lab. In the process slowly I was realising what that *philosophy* is. What I like most of programming is you don't need to have a great theoretical background to start writing good quality code. Important is figuring out the problem and applying yourself. In the process of applying automatically you learn many things which you didn't know earlier. Of course to write really path-breaking program you need to be extra-ordinary. That is true for every field isn't it? After all not every budhiya runs 65 Km at his age. There are not many Linus Torvalds, RMS or Bill Joy! I wish I had that mathematical back-ground to write an evolutionary search-engine. Recently I was reading a book by no one but Linus Torvals, where I found most beautiful explanation of this philosophy -
I'm personally convinced that computer science has a lot in common with physics. Both are about how the worlds at a rather fundamental level. The difference, of course, is that while in physics you are supposed to figure out how the world is made up, in computer science you create the world. Within the confines of the computer, you're the creator. You get to ultimately control everything that happens. If you're good enough, you can be God. On a small scale.
I was truly moved reading this. And thing is I no more hate philosophy as a subject. It's really nice feeling to make the dumb machine work as you want. It gives you lot of pleasure. I just can't stop quoting from another classic "The Mythical Man-Month" by Brooks -
The programmer, like the poet, works only slightly moved from pure thought-stuff. He builds his castles in the air, from air, creating by exertion of the imagination. few media creation are so flexible, so easy to polish and rework, so readily capable of realizing grand conceptual structures.
and
Yet the program construct, unlike the poet's words, is real in the sense that it moves and works, producing visible outputs separate from the construct itself. It prints result, draws pictures, produces sounds, moves arms. The magic of myth and legend has come true in our time. One types the correct incantation on a keyboard, and a display screen comes to life, showing things that never were nor could be. Programming then is fun because it gratifies creative longings built deep within us and delights sensibilities we have in common with all men.
.. I never realised when programming has transformed into a fascinating passion for myself.
and
Yet the program construct, unlike the poet's words, is real in the sense that it moves and works, producing visible outputs separate from the construct itself. It prints result, draws pictures, produces sounds, moves arms. The magic of myth and legend has come true in our time. One types the correct incantation on a keyboard, and a display screen comes to life, showing things that never were nor could be. Programming then is fun because it gratifies creative longings built deep within us and delights sensibilities we have in common with all men.
.. I never realised when programming has transformed into a fascinating passion for myself.
Oho! before signing off let me give a disclaimer. I never claimed to be a geek. I'm an average programmer with bit of passion for learning new things and writing better code. And betterment continues everyday. I dream of the day when I'll be able to write "good code, beautiful code, excellent code".
Subscribe to:
Posts (Atom)