Charlieplexing code

Use arrays, and try using direct port manipulation for the pin direction and the state. If you use two of the arduino's almost-complete ports, you will be able to accomplish what you do in 16 lines in 4 lines. http://www.arduino.cc/en/Hacking/PinMapping and Arduino Reference - Arduino Reference will be very useful

And also, great work! That looks really great and is impressive, especially for being new to the arduino.

Good luck