This is a list of the best sites on the net for practicing your coding chops, showing off your programming skills, and competing for fame and fortune. Exercise your brain by untangling obfuscation, applying algorithms knowledge, growing your inner math geek, or playing a bit of code golf. These sites have exercises to build on and refine what you already know, or learn the language du jour.

Code Golf

Code Golf

When: Ongoing, new challenges posted sporadically

Languages: Perl, PHP, Python, Ruby

How it works: Based on the original perl golf, Code Golf allows you to show off your code-fu by solving coding problems using the least number of keystrokes. The challenges cover a nice mix of topics; example challenges are 99 Bottles of Beer, Tower of Hanoi, The Game of Life, and converting Roman numerals to base 10 integers.

How to win: Submit your code, and if it passes the challenge test cases, your entry is scored according to the number of characters. Win bragging rights by appearing on the overall leader board or the leader board for each problem.

UVa

UVa

When: New contests every month

Languages: C, Java, C++, Pascal

How it works: Each contest consists of anywhere between 3 and 10 problems. The problem sets demand quick thinking and a good computer science background with solid knowledge of algorithms, data structures, and mathematics. Common themes are palindromes, primes, and graphs. Check out the extensive contest archives for practice.

How to win: Contests are timed and usually last several hours, so have some coffee and brain food nearby. Submit code for each problem to the automatic tester when it’s finished. Contestants are ranked by the number of correct solutions and ties broken by the time taken to complete the challenge.

Mindcipher

Mindcipher

When: Ongoing

Languages: Logic

How it works: Mindcipher is a social repository of the world’s greatest brain teasers, logical puzzles and mental challenges. No programming required, just logic and common sense. Some of the problems are taken from Google and Microsoft interviews so brush up your interview skills while having some fun. Categories of brain teasers are mathematics, physics, at the campfire, logical, riddles, lateral thinking, optical illusions, and general. Each puzzle is ranked according to difficulty and members can vote up favorite puzzles.

How to win: Answers are provided for each brain teaser, so there isn’t really any winning involved.

Project Euler

Project Euler

When: Ongoing

Languages: All languages

How it works: Each problem is designed to be solved by some combination of mathematical insight and algorithm design. Problems build on one another, getting progressively harder, so its a great way to keep your math skills fresh. After solving a problem you are given access to the forum containing algorithm discussion and solutions in a wide variety of languages, so Project Euler is a nice way to learn a new language.

How to win: Submit correct answers to the most recent 25 problems to earn a spot on the venerable Eulerians list. Or solve more than 200 puzzles to reach level 5.

TopCoder

TopCoder

When: Weekly rated competitions, and practice rooms that are always open

Languages: Java, C++, C#, Visual Basic

How it works: In TopCoder’s algorithm competitions, you have a set amount of time to complete the problem set (usually an hour). Code is normally developed inside TopCoder; there are multiple plugins that provide an IDE within your browser.

TC also holds “competitions” in bug fixing and component design, development, and assembly. These competitions are actually work developed on a speculative basis for companies who have outsourced development to TC, with “prizes” given to work with the best ratings.

How to win: For the algorithm competitions, develop, test, and submit solutions to the 3 problems in the set during the submission widow. After a 5 minute intermission you can view competitors’ code and challenge it by giving a test case that you believe will break the submission. Scoring is based on problem difficulty, time to complete the problem, results of the challenge round, and results of automated testing.

The International Obfuscated C Code Contest

International Obfuscated C Code Contest

When: Yearly (but currently on hiatus after 19 competitions)

Languages: C

How it works: Submit your most obfuscated ANSI C code. Each contest has a list of rules concerning code size, the build process, compile dependencies, etc. However, legal abuse of the rules is somewhat encouraged. Winners from previous years have all used nefariously tricky obfuscation.

How to win: Submissions are judged by a panel of judges based on how obfuscated the code is. Originality is important in both the type of obfuscation used and the purpose of the code.