BOTD: Figuring out computer science

2007/10/05

It is all about deep questions and problems computer science. Including the question whether such thing as computer science actually exists. I thing it does, but have occasional moments of doubts – mostly when I read something related to real science :-).

What does Andreas Zwinkau (it is read as ts-win-cow, my anglophone friends ;-)) think about it, can be found http://focs.wordpress.com/

His comments are amazingly deep for such a young guy. I wish when I was getting my comp-sci degree (1981-1986) we have had the same wonderful things these young fellas have now: ubiquitous internet and really world wide web with Google that actually makes it useful, Linux and many other wonderful open source projects (Apache, Jakarta, Firefox, Eclipse – you name it). Can you imagine studying computer science in a world where the Web does not exist (yet) ?


Book review: Dreaming in Code

2007/07/02

Thanks to long weekend and more quiet time in last couple of days (Happy 140th Birthday, Canada!), I managed to read something else than Ruby-ism/Rail-ism. Among others, I finished the Dreaming in Code by Scott Rosenberg, a book promising to explain why software is hard.

It is pretty tough question to answer. The way this books tries to address it is following the story not very well known open source project named Chandler through it’s beginning over period of 3 years. Chandler was – and still is – developed by the OSAF – Open Source Application’s Foundation, founded (and financed) by Mitch Kapor, who was before the founder of Lotus Development Corporation and designer of the “Ur-spreadsheet” Lotus 1-2-3.

The Chandler project – unlike most opensource projects was blessed – or cursed – by very solid financial backing, which allowed to hire fairly large team for fairly long time, without worrying too much about running out of time or out of money. It also contributed to quite ambitious goals (“Outlook killer”) and to lot of time being allocated and spent on design and research projects (known also as BDUF – Big Design Up Front antipattern).

For me personally the most interesting discovery from reading the book was how similar can be the issues in two completely different projects that lacks clearly defined goal and requirements. In Chandlers case, the basic design questions were open for unhealthy long time: what is the platform for the repository ? Is it going to be peer-to-peer system or using centralized server ? What is the proper set of features ? How the user interface would look like ? I found these questions so familiar and reminded me of one other (non-opensource) project …

Throughout the book, you can find lots of quotations, observations and pieces of wisdom related to our profession collected from variety of sources – books, interviews, Web. For illustration few of them:

“Joy is an asset. It may well turn out that one of the most important effects of open source’s success will be to teach us that play is the most efficient mode of creative work” Eric Raymond

“In science, the whole system builds on people looking on other people’s results and building on top of them. In witchcraft, somebody had a small secret and guarded it … Traditional software is like witchcraft …” Linus Torvalds

“In any project that is introducing new technology or design … plan to throw one away, because you almost certainly won’t get it right for the first time” Frederick Brooks

“… we should train developers the way we train creative people like poets or artists…. They study great works of poetry. Do we do that in our software engineering disciplines ? No. You do not look at the source code for great piece of software. Or look at the architecture of great pieces of software. You do not look at their design …” Richard Gabriel

Conclusion: Maybe not as easy read as originally expected – mostly because of the length and level of details related to Chandler, but nevertheless worth reading by all means. If you are professionally involved in building software for living, this books outlines many issues of the field. You may even have feeling terribly strong deja-vu (if you are around for couple of years/decades). Or – if you are younger – it can be a great example of things to avoid 🙂

Recommended.


Quote of the day

2007/06/21

The realization came over me with full force that a good part of the remainder of my life was going to be spent in finding errors in my own programs.

— Maurice Wilkes

What is so worthy mentioning on this obvious stament, describing fate likely shared by many thousand or milions of software developers worldwide ? Not much, only the date. According this book (which is a pretty good read btw),
Sir Maurice came to the sad realization mentioned above in the year 1949.

Just wondering – what have we learned since ?


Who is the most successful programmer of the world ?

2007/02/11

Depending on how you define success, you may get different answer to the question above.

If you choose for the success criteria:

– amount of money made by programming AND
– number of people using the product AND
– impact on the community at large

the answer is probably Charles (Karoly) Simonyi, Hungarian born ex-Microsoft employee, billionaire, astronaut and original author of Microsoft Word.

True, there certainly are people that made more money than him and their fortune is closely related to software – but unlike Simonyi none of them was actively programming for major part of their career. Take Bill Gates for example – most of his coding goes back to his teenage years and after creating Basic, his role was not related with active code writing. Also the number of people using Altair Basic (or any basic) today is likely nowhere in the Word league.

Simonyi is also creator of contraversial Hungarian naming notation of variables, which was considered to be “canonical” notation for programming Windows with C and C++, popularized by another Charles, the author of de-facto standard Windows programming textbook – Charles Petzold. In a nutshell, Hungarian notation adds prefix to each variable name which encodes its data type: for example: char *lpszBuffer means long pointer to string (zero-terminated).

The supporters say that this allows easy visual control of how the variables are used, e.g. from:

strcpy(lpszBuff, &cName);

is obvious (at least for experienced C programmer) that the code will crash, because the right side is an address of single byte character, not a string and there is no terminating zero after the byte, therefore the strcpy will likely overwrite the buffer and possibly stack.

The opponents say that modern languages and modern compilers make most of these checks available in the compiler and that the name should denote what is the role/purpose of the variable, not it’s type – as the type can easily change. Roedy Green calls Hungarian Notation “the tactical nuclear weapon of source code obfuscation techniques.” (see his recommendation How to write unmaintainable code and Mozilla programmer Alec Flett wrote (using Hungarian Notation):

“prepBut nI vrbLike adjHungarian! qWhat’s artThe adjBig nProblem?

How did I get to writing about Charles Simonyi ausgerechnet today ? The MIT Technology Review published fairly interesting article on him and his latest brainchild – Intentional Programming. The article is fairly long read, but quite interesting. The goals of Intentional Programming are very ambitious and it is hard to say, how realistic is it to achieve them at all. The domain specific languages are certainly fashionable and idea of having “WYSIWYG” for graphical construction of code is attractive. But is it doable ? The details on are sketchy and without trying it out, it is hard to make any opinion – but it looks much more like interesting research concept than the production-ready system.

Take the example on Page 13 – it reminds me a lot of what I have seen during my PhD studies: a system that works for some very narrow, textbook size example – small, well defined problem with perfectly described boundaries and no inter-dependencies, but is just impractical for any real life application. Metaprogramming is still one of the many Holy Grails of software engineering – and we often get confused by believing that adding another level of indirection will substantially change the nature of the problem on hand …

IMHO best quote from the article was the Wirth’s Law (after Niklaus Wirth):

“Software gets slower faster than hardware gets faster.”

This is so true, especially if you look on Vista’s hardware requirements and think for a moment about your subjective feeling how responsive is your brand new, 2 GHZ dual core notebook with 2GB RAM running Vista. Now try to think few years back (if you can go back to 1998-99) and compare this to the state-of-the-art machine you were using at that time – probably something like a single core 300-450 MHz Pentium II with 128 MB RAM running Windows NT 4. How did that feel ?

As far as I can remember, the feeling was about the same – while doing the same things – develop software, browse Web, write documents and do emails – the old notebook did not perform considerably worse, certainly not 2-3 times worse. So despite the 10 times increase in RAM size, speed/CPU power, disk size and disk speed, we have not gained much on the user responsiveness side. Vista looks much nicer, but the feeling of speed is the same … only software is many times more bloated.


Surf more in less time: Google Reader

2007/02/07

Back in stone age when most information available was actually printed on paper in forms of magazines and books , people experiencing the information overload invented techniques of speed reading to deal with it.

It worked – mostly.

Nowadays, we have most of the content coming to you through the browser window. Even if you can still speed read the web page, you can get even more speed advantage and quickly sort out the interesting content from the fluff by using the magic of news feeds, RSS, Atom and wonderful free tool Google Reader.

Rather that going to tens of favorites news web sites, blogs, etc you just subscribe to their feeds and the reader will show you whenever there is something new of interest. It also allows you to classify – tag the feeds and create groups, for example of Windows related blogs/news sites versus Apple related. It is completely up to you. You can also (as in Gmail) to “star” the favorite articles to keep them marked (or, to save a local copy in Google Notebook).

I have started to use the Reader again two weeks ago and never looked back. Now I have all my favorite feeds in one place and whenever I have some time (pretty rarely these days) I am trying to catch up. What I found very cool is bunch of tricks described in this lifehacler article.

My favorites are g+u keys as well as g+t/g+l keystrokes. Try them out.

And now for something completely different: tomorrow it will be 50 years from the death of the John von Neumann (or as he is known him in our geo-region – Neumann János (he was born in Budapest, Austria-Hungary in 1903). A computer science pioneer and world class mathematician. If the computer science, mathematics, physics had their own Halls of Fame – similar as the Hockey Hall of Fame – he would have place in all of them.


Software Oscar Award

2007/02/05

In software industry there are no annual awards and recognitions of achievements that would resemble the Annual Academy Awards of the movie industry. Various magazines, publishers and companies do present theirs yearly list of Best Products, but they are often biased and seldom representative. The one list that stands apart and that in my opinion comes closest the Oscar is Jolt Awards published by used-to-be one of the best magazines for professional programmers – Dr Dobbs Journal. It is still around and still a pretty good magazine, I guess – but the evolution of the Internet and shift of the money towards on-line advertisement changed the business landscape for most of the magazines, depending on revenue stream from ads. The list has various categories: for books (general and technical), project management, database systems and tools, IDE, design tools, development libraries and so on.

As with the movies, it is nice to discover that the movie you have seen and liked makes it to the “Best of …” selection. I have noticed that several of my favorite products were listed for this year – namely JIRA, IronPython, Liferay, Textmate, Koders.com and Codeproject.com. For last year, the match was even longer: Visual Studio 2005, SQL Server 2005, MySQL 5.0, JIRA, Enterprise Architect, Eclipse 3.1, Komodo, .NET Framework 2.0, Spring Framework, JBoss.

Go and have peek. You may discover your favorites in there too – or get some inspiration of the new apps to look at.


Unknown celebrity

2006/12/10

Yes, I know, the title sounds like oxymoron and to certain degree, it is. What it should maybe say is Person who should have been celebrity

I am not going anywere close to movies or entertainment industry with this. There are more than enough sites, blogs and gossip channels out there that look at life of movie stars or singers. I will stay within the world of computers and technology, which has its own heros and celebrities, albeit known in smaller groups. In “real world”, pretty much everybody knows Bill Gates, Linus Torvalds, Steve Jobs, Larry Ellison, Steve Wozniak. They have made the headlines many times. Fewer people know names like James Gosling, Anders Hejlsberg, Bill Joy, Dennis Ritchie, Guido van Rossum, Guy L. Steele, Richard Stallman….

Strangely enough, there is a name in history of human-computer interaction and computer technology that is associated with such significant advances as graphical user interface, networking, groupware and internet. This man personally invented computer mouse in 1967 and his team developed hypertext, whose most famous implementation is World Wide Web.

His name is Douglas Engelbart, and he is still working – in his 81 years, as the director of his own company, the Bootstrap Institute. He never made any money on his mouse invention – the patent expired before the personal computers and GUI made the mouse ubiquitous. At least, his company is housed rent-free courtesy of the Logitech Corp., company which made lots of many on computer mice manufacturing. Nice gesture, Logitech – I will keep buying your products :-).


Vista security and starting from scratch …

2006/11/30

I have read somewhere that quotation is safe way how to say something potentially dangerous or controversial without being legally exposed :-). So today I am going to quote an authority in computer security – Steve Gibson on some very interesting Vista related security information.

Steve is doing (together with Leo Laporte) excellent weekly podcast “Security Now!”. It is so great that I have decided to download as many back episodes as I could find on their site and started to listen to them in the chronological order, back from June 2006. It was worth of every minute. I am now somewhere in August 2006 and Steve Gibson (== SG) covered interesting tricks what to do with you hosts file, very nicely explained the usefulness of netstat program and started multi-episode sequence on virtualization and virtaul machines. Thanks to many years of experience, Steve always gives a historical perspective on every topic he covers.

What I want to mention (and quote) is the Vista security and Microsoft claims that

a) Vista is the most secure Windows system ever written and much more secure than previous versions of Windows

b) the Vista code was written from scratch which should be in support and a contribution to a)

As SG said, security is something that is earned, not claimed. No company can say that system XYZ is most secure – it can just release it and let the reality – how the system stands in hard battles of attacks – decide how secure or insecure the system is. For that reason, according to SG, saying anything about Vista security is at minimum premature – and nothing really new, because similar claims were made with release of Windows 2000 and Windows XP. The reality did not quite support that claim – and XP was at least unti SP2 a “land of worms”.

Microsoft claims to have fresh new TCP/IP stack in Vista, written from scratch. Unfortunately – according to SG – this time it seems to be so. The reason why “unfortunately” are implication of having new, untested “virgin stack” for security. SG offers nice historical perspectives on issues of Windows networking implementation – mentions famous problems like machine freeze on packet with spoofed source address being same as destination, SYNC flood attacks, the “ping of death” and how all these were found and eventually fixed. Now, with fresh new stack, at least one of these problems that was fixed long back in the times of Windows 95 re-appered again in Vista.

The episode also gives very interesting peek on history of network stack in Windows. As SG points out, Microsoft suddenly got in Windows 2000 very good, solid and mature networking implementation, a huge improvement in stability and performance against previous versions of Windows.

TCPIP stack is very complex piece of software and traditionally the most solid, most performant and certainly most secure implementation were found in open source Unix variants like FreeBSD and OpenBSD. Network experts use special tools to “fingerprint” the implementation – by sending specially crafted packets are analyzing the response, they can tell apart one implementation from the other, without actually having access to the stack’s source code. And strangely enough – according to SG – the greatly improved Win2000 stack showed amazing compatibility and similarity in responses, quirks and “fingerprint” to BSD implementation :-). Draw your own conclusion

I am pretty sure that decision to start from scratch and rewrite was carefully considered at Microsoft. There certainly were very many reasons for this: new features added, support for IPv6, and so on. Starting new often makes sense. What is wrong with it is presentation and marketing message that “it is much better because it is new”.

As this article in Joel On Software puts it

All new source code! As if source code rusted.The idea that new code is better than old is patently absurd. Old code has been used. It has been tested. Lots of bugs have been found, and they’ve been fixed. There’s nothing wrong with it. It doesn’t acquire bugs just by sitting around on your hard drive. Au contraire, baby! Is software supposed to be like an old Dodge Dart, that rusts just sitting in the garage? Is software like a teddy bear that’s kind of gross if it’s not made out of all new material .. “

We will probably never know what was the real reason for TCP/IP stack rewrite, neither will know how to interpret “amazingly similar” behaviour of Windows 2000 stack and BSD implementation. The recent events of complicated deals related to intellectual property between Novell and Microsoft, and rumors of possible legal battles on IP with other Linux vendors, do not make it any clearer either.

What almost sure, that despite the claims, we can expect old new bugs appearing in Vista networking and it will take quite some time until security experts as SG can test Vista enough to be comfortable with degree of security it really offers. I am in no hurry to upgrade – running Vista in virtual machine sounds like best approach right now, at least until Service Pack 2 :-).


Back again

2006/10/13

I have been back since Monday October 2nd late night, but until today, the backlog of things in both projects did not leave enough time to do any blogging. Not even any project-unrelated thinking – which is a prerequisite. Thanks to long weekend, I almost caught up with my backlog in both projects, so I can get back to the fun part of business such as Internet and blogs …

To answer the question how was the trip: Great!. Bratislava is really nice tourist destination (obviously, lots of British and Italian tourists must have found out too …). Especially if your main area of interest is meeting people in pleasant environment of pubs, restaurants and caffee’s, which are available in huge quantities in the historical downtown. This certainly was my main activity as I tried to meet many people from my “previous life”. I did meet most of the people I wanted to meet (as well as few I did not expect to ;-)). Weather was fabulous, food was good (maybe even too rich), beer was (as expected) excellent and really affordable ( < $2 a piece).

The only real problem is smoking. It is mostly allowed everywhere – pubs, restaurants, caffee’s, airports – you name it. In many places the idea of “non-smoker’s area” is virtual line drawn in the middle of the restaurant, with no air flow limitation whatsoever … It is not specific to Slovakia – Austria and Germany are pretty much the same.

Secret hint: if you go to Bratislava, take your notebook with you. In the heart of the pedestrian zone, right in front of the City Hall there is a free WiFi, courtesy of the city council. Too bad I noticed it only 5 days before leaving. Enjoy !

While I was travelling, few interesting things happened. The biggest (in both market impact as well as dollars transferred) was YouTube’s purchase by Google. I guess many lawyers in USA must be very happy and very busy now … as it is much more fun to sue somebody that actually does have money for copyright infringement, rather than cash-strapped startup. I dare to predict looots of such lawsuits. The lawyers will not have it easy – they may be challenging something really big. Not only financially. According to the Church of Google, Google is actually a real deity. And they claim to have a proof for it:

  • Google is all-knowing (Omniscient).
  • Google is everywhere at once (Omnipresent).
  • Google answers prayers.
  • Google is immortal.
  • Google is infinite. (a mathematician in me has serious issues with this statement ;-))
  • Google remembers all (now this is scary !!)
  • Google can “do no evil” (Omnibenevolent).

See the Full proof and their very own 10 commandments .

I can imagine this idea will create lots of emotional reactions. Depending on your personal standpoint in matters of religion and spirituality, you may find it all somewhere on the scale from “terrible inexcusable blasphemy – how dare you …” up to “excellent hilarious funny idea”.
Make your own choice. But regardless where you stand, consider this (now I am *not* promoting or advocating here anything, so no flame wars plz):

The Church of Google believes we should be tolerant of everyone’s beliefs, provided said beliefs hurt no one …

and

Googlism has not started any religious wars, forced its opinions onto others, discouraged critical thought, objected to harmless lifestyle choices and most importantly, we have never attempted to scare people into believing they will suffer if they reject our religion.

Can you say the same for your religion?

If you reject Google as your God, nothing negative (aside from your search results being crappy) will happen to you.

Enough of this – quick look at other noteworthy nuggets from the Web:

  • Roughly Drafted is very interesting read, especially if you have been around for a while, or if you care about history of computing. See the Rise and Fall of Platforms series. Recommended.
  • Ian Landsman’s thoughts on business of programming are also worth reading .
  • Thanks to these guys I found out that I am 50% average person (whatever that means). Here is why: they published “20 Things the average person doesn’t know about XP”. After reading them, I found out I did not know about 10 of them. Now I only wonder is 50% of average better than average or worse ?? <grin/>…
  • Web developers and Firefox users, note the 20 useful Firefox extensions for developers. Are there any web developers out the who would NOT use Firefox ? Just wondering …
  • If you use SQL Server, look at the T-SQL code snippets of this Narayana Vyas Kondreddi
  • Ever wondered whether Yahoo Maps are better or worse than Google Maps ? See side-by-side comparison
  • Another comparison – of anti-virus products can be found here

To finish in a good mood – here is how to shoot yourself in the foot in various programming languages


Harddisks turns 50 on September 13th

2006/09/05

It is hard to imagine – on September 13th it will be 50 years since IBM introduced the very first hard drive.

Since that time technology made quite a progress. Compare for yourself:

1956 – RAMAC drive

  • capacity: 5 Megabytes, built from fifty 24″ spinning disks
  • weight: about one ton
  • price: $250’000 / year (lease)
  • price per gigabyte: about fifty million dollars

2006 – typical harddrive

  • capacity: 500 GB
  • weight: < 1kg
  • price: ~ $300
  • price per gigabyte: about 60 cents

Amazing, isn’t it ?

See full article.