The Daily WTF

A friend of mine pointed me to this website, The Daily WTF, Curious Perversions in Information Technology.
On this website you can get your daily dose of funny, stupid or weird bits of programming code.

How about this bit of code for converting a byte array to hexadecimal?
Notice the use of constants to improve readibility, such as:

public static final int FIRST_BIT_OFFSET = 1;
public static final char ZERO = '0';

Here’s another nice example of the use of constants, to make SQL query building much easier!

› Continue reading

Tags: , ,

Tuesday, April 4th, 2006 Computing, Funny No Comments