Wednesday, 29 October 2008

Getting a new PC...

My sister told me today that the IT department at her employers have a load of old desktop PC's they no longer need, so they're going to be installing Ubuntu on them and selling them on for about £5 each. I'm guessing that they have some kind of licensing deal with Microsoft that means they get to use as many copies of Windows as they like, but if they sell them on they have to remove it, so they probably can't keep Windows on them.

I'm actually quite impressed with this, for several reasons:
  • It means perfectly good hardware can be reused and made available to someone else. In contrast, my own employers, who shall remain nameless, apparently have a deal with a company to break up all their computers and dispose of them, which I think is a staggering waste, and this is a BIG company that's in the FTSE.
  • People can get a working computer that's perfectly good for surfing the web, emailing and basic office tasks, for a pittance. It'd be ideal for people's kids or elderly relatives, neither of whom will care that much whether it runs Windows or not.
  • It's probably actually cheaper to do this as it must cost money to have them disposed of.
  • Plus, it exposes Linux to people who otherwise wouldn't try it.
She's asked if I wanted one, so naturally I said yes! So she'll try and get me one.

I see little point in sticking with the Ubuntu install already with it, as I run Ubuntu on one computer already and Kubuntu on another. So what to run on it? I have several candidates in mind:
  • Sidux
  • Xubuntu
  • Damn Small Linux (I've grown to love DSL in the last few months)
  • Slackware
  • Gentoo
  • Linux From Scratch (it'd be a hell of a challenge though!)
  • PC-BSD
  • FreeBSD
  • Debian
  • Linux Mint Fluxbox CE
  • Or I could use Ubuntu Mini Remix to create my own remaster based on Ubuntu, but using a lightweight window manager. I've done this in the past to try to create something that worked better on my Eee PC (unfortunately it didn't work out too well!), but the end result was perfectly useable. I'm actually very keen on the one I created purely for the fun of making it look as 1337 as possible (it's basically Fluxbox with the Matrix theme, a black GTK theme, and an abstract green-and-black background). I'm also interested in trying out some more window managers - I like IceWM a lot, I also like Fluxbox, I'm interested in trying FVWM, FVWM-Crystal and FVWM-95, and I may give some of the tiling window managers like awesome and Xmonad a try.
I'll have to wait and see how powerful the machine is before I can decide what to put on it, although if it's running Ubuntu OK it should be able to handle most Linux distros. That's assuming they haven't all gone!

I've never actually owned a desktop before. All my computers right now are laptops (a Dell Inspiron, a Philips X58, an Asus Eee PC 2G Surf, and a Santa Rosa MacBook), and much as I love them all, certain things, such as coding, are really better done from a desktop. It's a simple matter of ergonomics. So I'm looking forward to having a desktop computer of my own because I anticipate that it should improve my productivity.

Saturday, 25 October 2008

IT Guy vs Dumb Employees Video

I couldn't help laughing at this great video! Check it out!


IT Guy Vs Dumb Employees - Watch more Entertainment

Friday, 24 October 2008

Encouraging the programmers of the future

I found this interesting article on the BBC News website today about the British gaming industry, and how the UK has long been punching above its weight in the gaming industry. This has always been put down to the generation who grew up with BBC Micro's, ZX-81's, and so on. These computers generally had a BASIC interpreter build in, and you'd have to use that to run programs from tape or disk.

Thanks to these native, inexpensive computers, the UK was for years a strong player in the gaming market. Programmers cut their teeth by entering listings from a magazine, progressing to writing their own games. OK, the machines were arguably harder to use than a modern machine, but they were well documented, and there was more of a culture of programming with them - if you wanted to use one, you had to learn at least a few commands.

Now, contrast it with this article from earlier in the year, which makes for somewhat more depressing reading. Few people are learning about programming, and schools are concentrating on teaching kids how to use Word and Excel. No wonder so many people are reluctant to even consider switching to OpenOffice!

I'm nearly 30, and got my first computer (an Amstrad CPC 6128) aged around nine or ten, so I consider myself to be at the very tail end of the generation that grew up around the first home computers. Like many others, I worked my way through the tutorial in the phone-book sized manual to build an address book application, and spent hours typing in and debugging games from magazines. Being a kid at the time, I was regularly distracted from it, but I got to be OK at it.

The 90's were arguably a bad time for the computer industry in many ways, despite the fact that the Internet appeared during this decade. Commodore went under, Apple only survived by the skin of their teeth, and within the space of a few years, Windows came to dominate the desktop. Pretty much everyone else disappeared.

While Windows undoubtedly did a lot to make computers more accessible (much as I hate to admit it, as I am a Linux user!), it also relegated them to being something used for writing letters, making spreadsheets, and later, surfing the web. To a certain extent, it made a computer into a black box, as people weren't interested in learning to code.

At the same time, the games consoles began to draw much of the gaming market away from home computers. While some genres (RTS, for example), have long been strong on the home computer, and remain so, others switched almost wholesale to the console. Platform games such as the Mario and Sonic games are a good example of this. So people who in the past would have bought computers for gaming and got into programming later were rarer.

Nowadays, if you buy a Windows PC, you certainly don't get encouraged in any way to get coding. There's no guide of any kind included, nor do you get a BASIC interpreter (or any other interpreter, for that matter). Modern PC magazines don't seem to do anything to encourage people to learn to program, and I find that a little sad.

With a Windows computer, it seems to me that you actually have to be interested in coding to start with, and to know that you're interested in it, to be able to get to use it as a programming platform. By this, I mean it gives no encouragement whatsoever in learning to program in any language. Microsoft don't include any kind of programming tools at all as far as I can see.

The frustrating part is that they already have a pretty decent tool in the shape of Visual Studio Express Edition. OK, I'd rather people learn an open-source language than be tied to Windows, but I'd much rather see people encouraged to get programming in the first place. Why couldn't Microsoft include at least one of the Visual Studio Express Edition IDE's (I expect they'd probably go for Visual Basic, although that wouldn't be my first choice), and a manual (in print or pdf format), with every copy of Windows? They could place a link on the desktop that says "Start learning to program!", and let people's curiosity take over naturally. If people don't want it, they can delete it, and that's fine. As it is now, you have to go looking for it on the Microsoft website. They should be encouraging people to learn about their software and develop better applications for it.

I think that in many ways, Apple have done better in this respect. By including the Xcode IDE with every copy of OS X, they've provided a powerful tool with their computers. Also, OS X is at heart a form of Unix, making it well suited for programming. However, the fact that Xcode isn't preinstalled does mean it's not there by default, making it less likely that people will try it out of curiosity. Also, although Xcode does have loads of documentation with it, it doesn't include any kind of "beginners guide", it seems to be all for people who are already programmers. They could definitely do more to encourage people to start learning to program. I also think that OS X's polish counts against it in this case, as it means you never have to delve into the terminal to accomplish every day tasks. So again, I feel that like Windows, OS X does little to encourage people to learn how to program.

Another thing with both Apple and Microsoft is that they do emphasise IDE's over text editors. I've had a brief try at using Visual Studio Express Edition, and tinkered with Xcode, and I subscribe strongly to the view that an IDE is the last thing you want to use when you start programming. Learning a brand new and extremely complex application at the same time as learning to program is a bit too much for most people, whereas anyone can use a basic text editor. Even a more complex one, such as Vim (my personal favourite), is far easier to use than most IDE's. There's no doubt that IDE's offer a lot of features to experienced users, but they can be extremely overwhelming when someone takes their first steps in programming.

This is one of the things I like about Linux over OS X and Windows. While these days you don't actually have to use the terminal for everyday tasks in a modern distro like Ubuntu, there's a strong culture of doing so and you're encouraged to use it in solving problems. I think part of this is because the main support is through forums, and it's easier for someone to post a command for you to paste into the terminal than to say "Click this, then this, then this...". Also, the bash shell is a lot more powerful than its Windows counterpart. By and large, while there may be a learning curve, using bash is often the quickest and most convenient way to accomplish a task, and it doesn't take long for this to become clear. From using bash and changing settings by editing text files, it's not a great leap to then go on to write shell scripts or to learn to code using Perl or Python. Most distros also include a lot of documentation for the included languages. Also, languages used in Linux are almost invariably ones that can be written with a simple text editor rather than forcing someone to learn to use an IDE, which I feel makes them more accessible.

However, I still feel even Linux can do more to encourage people to learn to program. The last thing I'd want to do is to force people to learn to program when they don't want to, but I do think we should be taking more steps to encourage new programmers. Maybe just a nice handy pdf file in your /home directory called "Learn to Program" will be enough.

Having recently taken my first few steps in learning Python, I'm enjoying learning it tremendously. It's probably a more powerful language than BASIC, but I find it just as easy to get started with. Having had a go at Perl and Java in the past, and finding these a bit of a struggle for a first language, I was pleasantly surprised by Python. So it would make an ideal language to include with a new computer. OS X and most Linux distros include Python already, and I see no reason why Microsoft couldn't distribute a copy with Windows. Just add a pdf guide or two and sit back. If for some reason they didn't want to use Python, we're certainly not short of other good languages for beginners either.

How else can we get people interested in learning to code? What languages should we push? Should we encourage them to use an IDE, or go with a text editor like Vim? All answers welcome!

Friday, 10 October 2008

My project for this weekend...

I have a little project I've decided on for this weekend. I've previously set out to learn a programming language from scratch (most notably Perl, PHP and Java), and failed! I do have a fair grasp of HTML and XHTML now, though, so I'm pretty confident I can learn an actual programming language given half a chance.
I've long heard that Python is very easy to learn and today I read a passage where a programmer said he was able to learn Python in a weekend through just online tutorials. I've found these to be patchy at times so I invested in a new book, and I'm going to make a concerted effort to learn Python from scratch this weekend.
OK, I may not be able to get through the whole thing, but I reckon I should be able to make a lot of progress. I'm particularly interested in learning to use Django to create web apps as I'm planning a new career in web development.
Wish me luck!