Project Deliverables

IMG_0558-Edit.jpg

I really like having the students back on campus. I was talking to Cameron about Seed projects. He is on the fourth year of our MEng course and he will be developing a project for a proper customer as part of his course this year. He was asking for any tips about project management. I told him that the best way to regard a project like this is to consider that the outcome of the work should not be a product, it should be a happy customer. If you think you are making a Stock Control System then you will focus on the technical deliverables and probably get them working, but you might not provide what the customer wants. If you think about the problem in terms of making “Wonder Widgets” happy about the way they are now able to manage their stock that puts a different perspective on the job.

This doesn’t mean that you have to do everything the customer wants, including washing their car. What it means is that you should engage with the customer as much as you can (or they will let you) when you are building the solution. We have found that the best Seed projects are the ones where the customer really gets involved with the team making their solution. The best way to do this is to make it easy for the customer to work with you. Bring things to meetings to talk about and leave with lists of things to do. And keep the cycle as short as the customer will let you. Thinking “We’re OK, we saw the customer last month” is kind of dangerous, in that this is the way you end up with a half working solution to the wrong problem.

Welcome To Hull 2012

IMG_4917_8_9.jpg

That reminds me, must get down there and stock up before my first lecture…

Welcome to Hull for new students. And welcome back to everyone else. Firstly I must apologise for the horrible weather. My fault entirely. I washed both cars yesterday. Fool.

Anyhoo, each year I put up a bunch of tips for new students, so here goes for 2012:

  1. Make sure that you have all your updates installed on your system. It doesn’t matter whether it is a Windows PC, a Mac or a Linux netbook. Find out how to check for updates and get everything up to date. At some point you will want to connect your machine up to a campus network of some kind, and if you don’t have all the latest security patches you may be vulnerable to infection.

  2. Do something about viruses. At the very least make sure that your Windows PC has Microsoft Security Essentials installed and running, that the databases are up to date and that you run scans at regular intervals. If you really want to install an anti-virus program don’t feel obliged to spend a lot of money, the AVG free anti-virus program is good and will cost you nothing. Get it from http://free.avg.com/. Please don’t spend huge amounts on some of the more expensive ones. The benefits are dubious and they also have annual renewal charges too.

  3. Take a backup of your machine and leave it somewhere safe (perhaps even at home). Find out how to use the backup software on your machine and take a copy of everything. Use one of these cheap external hard disks that you can pick up for around 35 pounds or so from places like http://www.ebuyer.com/ or Staples, or even Tesco. That way if it all goes horribly wrong when you get to university you can recover your precious music, videos and other stuff. Once you have the backup habit, take a full one one every month or so.

  4. Don’t spend huge amounts on software just yet. Most universities (including ours at Hull) have deals that get you some programs that you need cheaply. Take a look at https://www.dreamspark.com/ for free Microsoft stuff and http://students.autodesk.com/ for free Autodesk stuff (great for 3D design).

  5. The same goes for books. In the computing field they are rather expensive, and you don’t want to pay a lot for a book and then find out that it is only used for a small part of the course. You can check the books out in the library, and you might also find that there is a second hand book sale on your campus where you can pick up the required volumes from other students quite quickly. You might also want to form a little cartel with fellow students to share books between each other and spread the expense (this is also neat because it can also give you a ready made study group). Hull students will get a printed copy of my C# Yellow Book (daffodil edition). Anyone else can get it free from http://www.csharpcourse.com/

  6. Get a usb memory stick (actually, if you are a Hull Computer Science student we’ll be giving you one of these later this week) . Keep backups of all your work on it. You can also use it to take files into the university to work on. You will get some filespace on the university network, but it will not be an enormous amount, and having your files always with you is useful. Put a file on the drive with your contact details (just your name and phone number) so that if you lose the drive people can find out who to return it to.

  7. Get some free on line storage. I like Windows Live Skydrive: http://skydrive.live.com/. This gives you 7 GBytes of space which you can access from anywhere on the web via a browser. You’ll need a Windows Live account to use this. Skydrive will also sync files across multiple computers, although I’ve found that that DropBox has better multi-platform support and also keeps track of file generations. Take a look at DropBox at http://www.getdropbox.com/. Unfortunately you only get 2G of Dropbox space for free. You can also use Google Drive: https://drive.google.com

  8. Make sure you have insurance for all your nice toys. It would be terrible if they got stolen or damaged before they were insured. Take a look at cover from student specialists like Endsleigh:

    https://www.endsleigh.co.uk/student/student-insurance/

    (if anyone knows any cheaper deals feel free to let me know and I’ll update this post)

  9. Start blogging. Good writing skillz, like wot I have, are very valuable and make you a much more employable person. Sign up at Hull Computer Science Blogs: http://hullcompsciblogs.com/ and start putting your word out and building your brand.

  10. Don’t worry. Really. You’ll be fine. And it will stop raining. Probably in April.

More On Broken Software

IMG_4611.jpg

It’s not as if I’ve been lying awake at night worrying about writing software (OK, perhaps slightly) but I have been pondering the “Is everything broken?” question a bit. And I’ve come to the conclusion that, at the end of the day it probably is, but then again it doesn’t really matter that much.

All of the terrible examples that are quoted are irritations in the great scheme of things. Nobody has been hurt, nobody is going hungry because of them and if the worst thing that happens to you in your life is that you can’t put any more music on your iPhone then I really, really, want a life like yours. True, it is annoying that things don’t always work as they should, and true, it would be nice if people felt moved to provide higher quality than they sometimes do, but at the end of the day stuff mostly works, and that is the important thing.

Technology now lets us do things (albeit imperfectly) that we just could not do before. It is also a great leveller. The Queen might have an iPhone that is covered in precious stones (although she might deem that a bit tacky) but she can’t do anything with it that you can’t do with yours. Although she might not worry as much about roaming charges as you do. The best phone in the world, whatever that is, can be obtained by literally millions of people, not just one or two. And, what’s more, anyone can make programs and sell them on the devices, providing a path to riches that just wasn’t there in the past.

I think, at the end of the day, we are always going to be upset with the status quo, and want it to be better. I vividly remember reading a piece some time back that was written by a retired general type. He was moaning about the way young people were more useless and lazy than he was in his day, and how their lack of discipline and application would lead to the collapse of civilisation as he knew it. Turns out he was a retired general from the Roman Army and was writing this a few thousand years ago.

The best thing to do is to take these issues on board, try to move things on a bit and give our children something even more fantastic to complain about when they get to our age.

On Broken Software

IMG_4097_8_9.jpg

Both Scott Hanselman and John Batelle have been having problems with their software over the last week. Both their posts are well worth a read.

Years and years ago Gerry Weinberg wrote "If builders built buildings the way programmers wrote programs, then the first woodpecker that came along would destroy civilisation". Not much has changed since.

It's always more fun (and more lucrative) to make and sell new stuff than it is to mend broken old stuff. And software lets you sell stuff that isn't finished. Unlike things like bridges: "Hey, that doesn't reach the other side!", and buildings: "Hey, where's the top floor?", many faults in programs take a lot longer to show up.

With a program you can leave out error handling, load testing and all the other boring bits that make a program properly useful and still ship a product that will sell by the boatload. With a bit of luck not that many people will notice. Of course, you could spend a lot more money and time getting it right. Snag is, I don't think that anyone would stay in business today making completely perfect software that took ten times as long to write as the current state of the art. People will go for new and shiny over old and working most of the time I'm afraid. I don't think I've ever seen an Engadget post about a new version of a product that is exactly the same as the old one, but works properly.

I’ve been writing software for an unfeasibly long time and some of it has wound up in the hands of proper users. I pre-date objects, Test Driven Development and pair programming. I wasn’t there when the loop was invented, but I I think I saw it in the papers. When I write a program I worry about everything, particularly what could go wrong. To me “The Happy Path” is an aside. I’m spending all my time fretting about “What happens if the response never comes back?” or “What if I get millions of these when I only asked for five?”.

It drove me nuts when I found out that the standard input/output libraries in C didn’t actually check the length of what was given to them, making the potential for buffer overrun part of the run time experience. I wrote my own input validation suite. I put it in all my products. I added timeouts everywhere. I didn’t particularly do this as part of a methodology, I just did it because it seemed sensible at the time, rather like a builder would make the ground floor before starting second floor. My programs hardly ever went wrong. Even the really big ones.

As a person who also teaches programming I try very hard to make sure that students take this approach when they write code. We start with defensive techniques and move on from there. As soon as you have a need for a number (say perhaps the age of your customer) then start to worry about how it might go wrong, become negative, very large, or change by more than 1 after a year. I don’t see this as tied to any particular methodology, I just see it as common sense, and I really want my students to have the same mind-set when they write their programs.

Modern development environments give you a lot more tools for making products that can be more reliable. Of course, the flip side is that the products can also do a lot more and that the demand for new, innovative solutions delivered in record time has never been greater. For me the only really good news is that where it is important to get code really right, for example in cars, airplanes and nuclear reactors, the software industry does seem to be able to deliver properly working systems, albeit slowly, and at great expense.

For the rest of us, I think it is as much our fault as anyone else’s that we are in this situation. We are keen to queue up for the next iPhone when the one that we have doesn’t actually work properly. Until we start only buying software that really works (and probably paying more for it) then this is how things are going to stay.

How to get more Blog Traffic

DSCF4799-Edit.jpg

Danny Brown, one of our students, is celebrating his 10,000th blog reader. Well done sir. I tell all my students to start doing things, and get a blog out there about what they are doing. I seem to remember that Danny had a blog before he came here, but I note that quite a few Hull students are now active bloggers. You can find out what they are up to at http://hullcompsciblogs.com/ There are some really good blogs to follow up there covering everything from Raspberry Pi to video games to Gadgeteer.

I’ve been blogging for very many years and do it for fun. Although it is nice to get traffic as well. If you want some tips for a successful blog, well, here are some of mine.

Track your users. If your blogging site doesn’t provide tracking of hits then install something like Google Analytics. It costs nothing and it gives a great insight on how much activity you are getting. This can be quite depressing, but it is always useful to know when you have done something that attracts interest.

Make sure you have metadata that makes sense. I’m not going to suggest Search Engine Optimisation as such here, just common sense things to help people find you.

Integrate your blog with social media. I use Windows Live Writer (part of Windows Live Essentials) for creating blog posts. That provides plug-ins that I can use to tweet and post on Facebook when the blog is updated. You can use If This Then That (an amazing service that I must devote a proper blog post to later) to do this for you automatically. And remember that comments on your posts will not arrive on your blog posts, they will now often arrive as Likes on Facebook or Tweets.  This means that if you want to have a dialog with your readers you have to go out and look for their comments.

Some content gets a lot less interest that others. The absolute best content you can create is stuff that solves problems. If you make posts that tell people how to do things then you will get a lot of traffic as people find your answer and link through to it. You will also get traffic via search engines. Pick a subject you know a bit about, or are learning yourself, and put up blog posts with answers to the problems that you hit. One reason Danny has had so much success is that he has provided some neat technical answers (with all that a reader needs to solve the problem) along with the other content. Readers might not care about the place you went last week, or what you think about the current government, but they do like being able to solve problems. The only downside with useful content is that such readers are “fair weather friends” who will bump up your traffic for a day or so, before it drops back down again. The way to address this is to put plenty of stuff on your landing page that will encourage them to look around and find other things to read.

Enjoy your blogging, keep it regular and leave the readers thinking that you like talking to them. You don’t need to post every day. Only a fool would do that. But a regular blogging heartbeat is a good thing. If you take a break don’t worry, or feel like you have to “fill in the gaps”, just come back with a good post and it will be like you never went away.

Teaching in “Sometimes Useful Shock Horror"

IMG_7895-Edit.jpg

If any of my students ever want to bring me a completed exam script I’m always happy to “mark” it in front of them. Quite a few take advantage of this and it really helps their grades (folks on 08120 – there’s still time before Thursday)

I’ve spent some time today going through answers and I’ve noticed something that worries me every time I see it. Some of the answers were just about spot on, but didn’t leave me with the impression that the student giving them really knew what they were talking about. It was as if they were just giving responses that they had learned, rather than speaking about something they understood. Now the thing is that this approach probably works fine if you are learning about Kings and Queens of England, but it is very different when we are teaching something that we really want you to apply. A lot of the stuff that we are teaching is intended to be applied to solve problems.

The thing to remember, if you are stuck in this revision thing, is that it is much more sensible to put effort into trying to understand the topic that it is to work really hard just remembering things. I never really got to grips with the piano because I was too “lazy” to learn how to sight read music for my left hand. So I’d just learn the left hand bit in time for the lesson that week. Of course, eventually this technique broke, when I found that the next exam had a “sight reading” test.

Learning to program is like this. You can learn “If a class implements an interface it must contain implementations of all the methods specified in the interface for it to be possible to create an instance of that class”. Or you can work out that we have interfaces so that we can build systems that deal with objects in terms of what behaviours they have (these are the methods specified in the interface) rather than the class hierarchy that they are part of.

Knowing the former will get you half the marks in the exam. Knowing the latter will let you create a mechanism whereby all the objects in your solution, the receipts, customer records, addresses, invoices and product descriptions, can be sent to a printing process that just asks them to print, and doesn’t care what type of object they really are because all the objects implement the iPrint interface which contains a “PrintToPaper” method.

If you want me to go through any of this stuff please come and see me and I’ll be happy to do just that. You can also post questions on the forum, and use the Twitter tag #08120Revision for quick questions. And don’t forget that we are not telling you this stuff so you can reflect it back to us in exam answers, we are telling you this stuff so you can use it to make things work.

I always find it amusing when students come back to me after a while on the course and say “That thing you taught us, turns out it is actually useful”.

Well, duh.

Please Do Learn to Code

IMG_5859-Edit.jpg

Tuesday night was not a happy one in the “Land of Rob”. First off I read this post from Jeff Attwood which argued that it is pointless for “normal” people to try and learn to program. Most depressing. Then I watched some of The Matt Lucas Awards Show, a rather vacuous and self-congratulatory program where the “celebrities” were invited to identify the subjects they hated most at school. One said “Maths”, another said “Computer Science”. They followed up with examples of why they hated the subjects so much, and even brought on an obviously very talented maths teacher just to make fun of her. Ugh and Ugh.

Two sides of the same coin. An expert telling non-experts not to bother learning their subject and two apparently “successful” people who seemed proud of the fact they hated the same subject. Two rules I work by:

  1. Never be proud of your ignorance.
  2. Never dismiss those who you think know less about something than you do.

The only great thing about this is that today Scott Hanselman, a proper computer person and almost a celebrity, turned up with the perfect response in his blog.

Tight–Loose-Tight

Sprite.jpg

I don’t usually regard The Apprentice as a ready source of business acumen. Still less The Apprentice You’re Fired. But a couple of weeks ago they had a chap on, forget his name – think he runs a chain of restaurants, who said something I thought was very sensible. He talked about his philosophy for team management. He said that he used a “Tight – Loose – Tight” approach.

  • Tight – get your team together and make sure that everybody is absolutely clear about what you are all doing, the part that each person must play in the enterprise and what they must deliver.
  • Loose – let the people get on with it. Don’t interfere with what they are doing or insist on doing it “your way”. (He made the point that this requires quite a bit of bravery and trust on the part of the project manager)
  • Tight – once everyone has done their bit, get the team together and make sure that everything has been done and have got where want to be.

I quite like these ideas, I think they are probably enshrined in a management textbook somewhere, but I don’t know much about management, I just try and get things done and make everyone happy.

Universities and Gymnasiums

DSCF2714-Edit.jpg

Something that one of the speakers said at the “do” last night has stuck with me. He said that, with students paying more and more for their degrees there was a danger that they might be seen as consumers of education, where they were obtaining their qualification by paying for it. He suggested another way of looking at the situation that I hadn’t heard before.

He said that going to university was like joining a gym.

You can join a gym to get fit, but just joining doesn’t make you fit. It simply gives you access to machinery and expertise that you can use to get fit. If you fail to listen to the trainer or make use of the equipment then you don’t get a better body, you just get poorer.

I really like this way of thinking. I think it puts all the responsibilities in all the right places. Our job as educators is to make sure students have all the stuff they need to make progress, but at the end of the day it is the student that gets their qualification.

Best Programming Language?

IMG_7331-Edit.jpg

There’s a program in the App Store called “Best Camera”. It takes as its starting point the idea that “The Best Camera you’ve got is the one that you have with you at the time”. The application then goes on to provide all kinds of useful tools that make the iPhone camera as good as possible.

I was reminded of this when there was a tiny bit of debate on my post about the CodeAcademy site, which teaches JavaScript. Now, JavaScript is not a great language, but it works and can be used to create useful stuff. So it is automatically a candidate for “Best Language”. In my opinion, the Best Language is the one that you are using at the moment. I base this on “Robs Rules for Programming Languages”:

  1. You can write great code in any language.
  2. You can write horrible code in any language.
  3. The user does not care what language you used to write the program they are using. The user only cares that it works and does what they want. And that they can afford it.

I’ve written programs in loads of languages. At the moment my personal favourite language is C#, but I have really fond memories of writing embedded C, since in that I could do anything I wanted and I could build all the underlying bits myself from scratch.

This is usually the point that people say things like “But blah doesn’t have blah.” or “Blah programs are really hard to use because the debugging support sucks.” So what. This brings me to the Rob’s Other Rule

  1. Having a nice place to work is much more important than the programming language you are using.

If the language you are using doesn’t have a feature that you need, find a way of programming around it. I’ve written lots of object oriented software in C. C doesn’t support objects, but I arranged the code so that it looked like it did and then programmed by “object rules”.

If the development/debugging support is horrible, wrap something around your program to make it easy to work with. I’ve built emulations of LCD panels and even lasers to avoid having to debug my programs on the real hardware. I’ve written code to make ten thousand customers from nothing, to save me having to type things in by hand. And I’ve added cheat buttons to games so that I can skip levels and inflate my scores and avoid having to play the game all the way through so that I can debug the last bits. 

Remember, when you are writing a program you don’t just control what the code does, you also control the environment the code sits in. Bending this to make things easier is something that will pay off tenfold. Can’t debug your program without a network connection? So what. Fake the web request responses so that you can feed the answers back yourself. This also makes test driven development much easier.

Of course, given the choice, you should pick the most appropriate language for the task. Give me an AI problem and I’ll be looking hard at what Prolog (or perhaps F#) can do for me. But for me programming is not about the language, it is about the problem solving, and that means a programmer should be able to turn their hand to whatever the occasion demands. Even if it is JavaScript.

Making Kids Creative with Computers

Hornsea Lights

This seems to be the year that the education system woke up to the fact that getting kids to make things with computers is a good idea. Excellent. I’m sure it was my blog post yesterday that tipped the balance….

Anyhoo, if you’ve got kids and you want to get them into programming here are my tips for tools that you can use. Note that these are just the ones that I’ve heard of and used, there are lots of others. If you have ones that you want me to mention, let me know and I’ll add them.

Making Computers Do What You Tell Them

These systems get kids used to the idea of logic and control. They have strong gaming context, but that is not a bad thing because it is engaging and gets kids thinking in the right ways.

Little Big Planet – making games goes mainstream. A great way to play games with your kids, create stuff and get things out there. Lots of scope for making things and showing off.

Wairo Ware DIY – make your own mini-games on Nintendo DS. Great fun.

Kodu – make games that run on your Xbox 360. All the programming is done using the gamepad and it is very easy to get interesting game behaviours.

Scratch – wonderful, free platform for the PC and Mac that lets students build fun games using their own assets.

Alice – great little scripting language.

Fiddling with Hardware

There is nothing quite like making hardware jump around and lights go on from software control. Kids love this.

Lego Mindstorms – a bit pricey perhaps, but no more than a few computer games. And you get Lego quality components and a really nice development environment that lets you create some very complex behaviours. Can also be used as a stepping stone into real robotics via things like Microsoft Robotics Developer Studio

Arduino – a good way to get your hands dirty of you want to make things out of tiny components. Lots of add-ons and an easy programming environment to get to grips with. Great if you want to learn some electronics along with your programming.

Gadgeteer – just coming onto the market. If you have folks who can write simple programs (Java or C#) and want to give them an easy way onto proper hardware then this is for you.

Writing Proper Programs

This is were we get more serious. These are tools that take you into the world of proper program development. They are not to be taken lightly, but they do let you make things that you probably can sell.

Small Basic – a version of basic that is free, very easy to understand and works a treat.

XNA – a very easy to use game development environment which takes C# skills and lets you write proper games using them.  Start at the create hub and find a wealth of resources for learning and making games and programs.

A Word of Warning

Learning to use computers creatively is hard work and involves lots of practice. Just like learning to play a guitar is hard work and involves lots of practice. I’d hate folks to think that because these tools make it easy to get started (and they do) that making things that are properly impressive and useful is easy. It isn’t.

The ones that are best at writing software are the ones that are prepared to put the time in fiddling with their programs, persisting with them when they don’t work and polishing them to a high gloss when they do.

Be prepared for the moment when your kids get into computers and they find that actually they have to work at it. Good advice in this situation:

  • Too many ideas can kill you. Does your game need helicopters and evil rabbits? And laser guns? And an equipment shop? Kids latch on very quickly to the idea that with a computer program you can do anything. Unfortunately they often then try to make a program that does everything. Then they find they can’t and get disillusioned with the whole business. Suggest a step by step approach, and throwing things away if you don’t really need them just yet. After all, if the player never knows you meant to put evil rabbits into the game they will never miss them.
  • Make your steps as small as possible. Get something small working and build on it. Get the ball to bounce, then add the paddles, then add the targets, then add the boss level and so on.
  • Walk away for a while if you get stuck. Don’t spend more than an hour on any problem. If you haven’t solved it in that time, do something else for a while and go back.
  • Other people’s code is dangerous. It is very tempting to just search for a program routine to do what you want. But this often ends in tears. You are using something from someone you have never met, which might not do exactly what you want, and might not work. If there is one phrase that worries me when someone describes a problem they are having with their program it is “I found some code on the internet…”. If you make the effort to write the code yourself then you have a much better chance of understanding what went wrong. Having said that, don’t be afraid to look at the work of others and get ideas from it. In that context I recommend  CodeProject and StackOverflow – but remember that these are for proper programmers.
  • Remember that this is supposed to be fun. If you are doing something that seems to be a bit of a grind, find a way of making life easier for yourself. Simplify the problem or use your computer skills to make a tool that will help with the work.

Computer Science is Creative. Fact.

Hornsea Wide Beach

The Guardian has just produced an article with the rather depressing title “Britain's computer science courses failing to give workers digital skills”. You can read it here. The gist of the text is that ‘poor quality training’ and ‘sausage factory’ courses are not providing the skilled and useful people that industry needs.

Oh dear. I always feel a bit nervous when I read these things. I start to wonder if what we do at Hull gives our students a good experience and teaches them skills that make our graduates properly useful. I cheer up a bit when I consider that we actually do a pretty good job for our students with things like Three Thing Game and Evil Squash to get their teeth into and a taught Masters that puts them out into industry. Plus lots of other things I haven’t got space to mention here. And then I remember how our students actually end up doing quite well in industry.

However, I also wonder a little bit about the place of Computer Science in the world.  Some time back The Guardian (same paper) did a big feature called “Top Artists reveal how to find Creative Inspiration”. I found this really annoying. Not because the folks that were there weren’t creative, or that their tips were silly. No, the reason this made me cross was the unspoken assumption that only arty types can be creative. I reckon that Computer Science is the most creative thing you can do. A writer can produce a book about an idea. A composer can create a song about it. A playwright can write a play about it. But a Computer Scientist can bring the idea to life. Which would you rather have, a song about Facebook or Facebook?

Computer Science is the most creative thing you can do. One of the few things we know for certain about the future is that it will be built using digital technology. Everything around us is being converted into patterns of bits and connected to everything else. Of course there are some bad Computer Science courses out there and of course there is confusion about what the subject is actually about. But what it is really about is building the future. And you can’t get more creative than that.

Marking Evil Squash

evilsquash Logo
This is a much better logo than my version. Thanks Jamie

I’ve spent the last three and a bit days in the lab marking first year student work. And it has been great fun. There were four of us down there watching students go through 15 minute presentations of their Evil Squash implementations. For those of you who haven’t heard of it, Evil Squash is a board game for up to 4 players. It is a kind of cross between Snakes & Ladders and Ludo. We invented it just for the practical session and we are going to invent another one next year.

Our first year students had to create a program that implemented the game, getting all the arrows on the board to work, along with the “Squash” behaviour that is triggered when one player lands on top of another. We provided a “special” dice sequence which allowed us to test all the game actions and we watched each program run through this. Then we took a look at the code, gave marks for style and any extras (some students added AI players who could take on their human counterparts), checked on user documentation and test reports and finally gave out a mark.

We always do a game development for the first year course, but this is the first time we’ve used a brand new game of our own devising. It has worked rather well. Everyone got into the spirit of the development and we have seen some very impressive implementations of the game, including a few Windows Phone versions in Silverlight and XNA. Expect to find Evil Squash in the Windows Phone marketplace soon.

Once nice side-effect of using an original game was that there was no code out there for people try and use. When people get into trouble with a development there is sometimes a tendency to leap onto a search engine and look for code that solves the problem. This is never a good thing to do. A lot of code out there is buggy and hard to understand and often takes you further away from where you want to be. During the marking we ask for bits of the code to be explained to us, and I found that for the ones I marked everybody knew how their code worked. Even those unlucky souls who hit bugs during the presentation were able to say “Aha! I know what is wrong and how to fix it” and point to the code block that was causing the problem. 

We saw some great work, and gave some great marks out. I’m really looking forward to what they turn out next semester.

Programming Humans with Evil Squash

Main Board Hi Res

I’m gaining a new respect for board game designers. It turns out to be quite difficult to create rules for the games that are unambiguous and easy to understand. Even what I thought was a simple game, Evil Squash, has turned out to have some nasty edge conditions that we have had to think quite hard about.

Of course, a game design is really a “program for humans”. It is a sequence of instructions that involve the processing of data, with decisions and outcomes. The tricky part is that the rules are written in English, which is a language in which it is very hard to make yourself completely clear.

Perhaps as an introduction to programming we could get a bunch of people to design the rules for a game of some kind, and then “debug” it by playing the game. I’m certainly going to invent a new “imaginary” game for each first year programming course from now on, just exploring the rules and getting students to think about how they work has given a nice new dimension to the coursework.

You can find out more about the game itself at www.evilsquash.com.

Whatever Happened to Flickr

DSCF4802

This is a bit of cautionary tale I guess. I’ve been using Flickr for many years as a host for my pictures. I found the service so good that I’ve even been paying for it. Until now. Suddenly uploads are going like treacle, the web editing doesn’t work properly and other photo sharing sites are powering ahead with innovations that make Flickr look pretty long in the tooth. Snag is, I’ve got thousands of pictures up there, many of which are linked through to my blog – like the one above of Scarborough harbour.

So, do I stick with Flickr, and hope that their parent, Yahoo, decides that it is worth investing in, or do I jump ship to another company which might go the same way in five years? The cloud is a great place to put stuff, but I think we need to remember that not all clouds stay the same forever.

Monday Reminders

Leeds Market

A couple of things to remember today:

Optimus Quest 2

If you want to send me some Windows Phone Marketplace stats before the end of the month (i.e. tomorrow) then you might have a chance to win an LG Optimus 7 Windows Phone. Send your screenshots of the Marketplace to optimusQuest2@robmiles.com

Job with Rob

The closing date for applications to the Knowledge Transfer Partnerships (KTP) which I mentioned earlier is quite soon. If you fancy working on a really interesting project in a nice part of the world you should get your applications in before Thursday.

A Job With Rob

Downtown Boston

One of the great things that the university does is Knowledge Transfer Partnerships. These are set up to do two things. Get students into good jobs and spread expertise into business. We are presently setting one up and I’m one of the academics at Hull University who is involved with managing the work. It is a very interesting project in a nice part of the world (not Hull actually) with good pay. If you are a recent graduate who wants to get started in the business you could do a lot worse than apply. Even though you might end up in meetings with me….

There are lots of KTPs out there. The one I’m talking about is here. You can find lots more, including some others from the university here.

What’s Wrong with this Picture Answer

image

Why is this stoopid?

There is nothing wrong with letting you run the program from the last successful build. Perhaps you want to quickly show somebody what your program looks like, but you are in the middle of editing it. In this case you just click Yes and that person can see your program running, even though it won’t build at the moment.

The problem for me (as some of you have already spotted) is the nasty “Do not show this dialog again.” check box. If you check that it means that Visual Studio will always run your last successful build without giving you a message. The scenario where this bites you is as follows:

  1. Run program, notice an error.
  2. Edit source code, fix error but forget to type semi-colon, leading to a compilation error.
  3. Run program again to see if error has been fixed. Program fails to compile, so Visual Studio runs the old old version without telling you. The error appears to be still there.
  4. Go nuts trying to find the error that you have already fixed. Every change you make has no effect. Give up programming and become a beekeeper.

An experienced programmer will be looking out for compiler errors and will know that they are running old code. But not everyone will. You can get a similar effect by working on the wrong source file. In that case you got the fix right, but a file somewhere else is being used in the build. If I suspect a “reality fault” like this I do something that is guaranteed to break the build:

wobble;

This should not compile and run. If it does, something else is happening. If you want to put this back to how it should be (in my opinion) you can go to Visual Studio Tools>Options and find the following entry:

image

Change “Launch old version” to “Prompt to launch”.

image

If you want to get rid of the dialog box completely, and never have the program run when it won’t build, change it to “Do not launch”.

I’ve been racking my brains as to why you would want to hide the dialog box and always run the old version. To be honest, I can’t think of a reason why you’d want to do this, and I’d be a bit happier if the folks at Visual Studio hadn’t.

Stalked by an Oven

image

I’m being stalked by an oven. It’s actually very scary. We are in the process of planning an upgrade to our kitchen. It should be completed this century with a bit of luck. As part of this I’m searching for prices of various kitchen appliances, including the device you see above. However, now pretty much every web page I go to has an advert for this oven appearing on it. Something in the interwebs has cottoned on to the fact that I’m in the market for some cooking equipment and is tailoring what I see to suit. Most interesting.

Web pages are highly aware of the searches I’ve been doing. Last week there was a very good article in the paper about this kind of thing, which made the point that what you see on the web and when you search depends on what you have already looked for/at. This is not something that you might expect. It means that, far from allowing the web to expand your creativity and send you down new avenues, what really happens is that after a while the search tends to contract and focus down onto what the engines think you are interested in.

Discovering this hot in the heels of the presentation from Sir Tim Berners-Lee last Friday on his dream of an open and level playing field for all internet users makes me wonder if somewhere a battle has already been fought and lost.

I’m not sure if anonymous browsing would make a difference, or if search aggregators like duckduckgo.com would help. As someone said last week “If the service is free, you are the product”. That is how it is with search these days.