Deprecated: The each() function is deprecated. This message will be suppressed on further calls in /home/zhenxiangba/zhenxiangba.com/public_html/phproxy-improved-master/index.php on line 456
Code Golf | Home
[go: Go Back, main page]


What is Code Golf?

Based on the original perl golf, Code Golf allows you to show off your code-fu by trying to solve coding problems using the least number of keystrokes.

You're not just limited to Perl either - PHP, Python and Ruby are all available too.

Challenges are always open, and your entries are automatically scored so you can start playing right away!

News [View All] [RSS Feed]

Tower of Hanoi

Posted 13.04.2007 by carldr.

To celebrate the first Friday the 13th of 2007, we have a new challenge for you kerrrazy golfers. I’m sure most of you have heard of the Tower of Hanoi. This challenge requires you to take a starting position of the puzzle and organise the pegs onto one peg. Read all about it on the Tower of Hanoi challenge page, where you’ll see all the information you need.

I’m going to make the bold promise that we’ll have a new challenge next Friday, but I’ve said that before so we’ll see if it actually happens!

Musical Score

Posted 08.03.2007 by carldr.

It’s been more than a month since the last challenge, many apologies for the delay in posting a new challenge. So let’s hope you like it!

Musical Score asks you to parse a music score and output the notes which are represented on it. In my opinion, it’s quite an interesting problem. As usual, visit the challenge’s page to see the full details.

We’re hoping it won’t be anywhere near as long until the next challenge, and there have been a few interesting challenges posted on the forums. If you have any suggestions, you can post them there, or email me them at the address at the bottom of each Code Golf page.

Scheduled Downtime

Posted 12.02.2007 by carldr.

A quick note to let you all know that there will be roughly 30 minutes downtime from about 16:30 GMT tomorrow (Tuesday) afternoon for some essential server upgrades. During that period the Code Golf server will be completely unavailable.

Roman to Decimal

Posted 04.02.2007 by carldr.

A new challenge has arrived in the shape of ‘Roman to Decimal’. The problem is exactly as it sounds – Your code will be given some Roman numerals, and it will have to convert them to the system we’re all more familiar with.

There are 25 test cases, so hopefully there won’t be any luck-based submissions for this challenge!

Thanks must go to Flagitious for putting this challenge together, as well as writing the description. Good work man!

Join The Fun!

If you're enjoying Codegolf, how about visiting our IRC channel? Get help with your challenges, talk to the regular (and not so regular) players, give us your feedback and generally join in the Code Golf community.

#codegolf on irc.freenode.net

Top Golfers [View All]

View the Overall | Perl | PHP | Python | Ruby leaderboard.

Rank User Score [?]
1st shinh 219,654 (24 challenges)
2nd flagitious 216,951 (24 challenges)
3rd ySas 211,896 (24 challenges)
4th kounoike 194,498 (24 challenges)
5th yvl 188,197 (24 challenges)
6th Mark Byers 178,858 (24 challenges)
7th yowa 170,565 (24 challenges)
8th irori 161,003 (21 challenges)
9th hiro.suzuki 152,757 (24 challenges)
10th carldr 150,725 (20 challenges)

Latest Challenges [View All]

Tower of Hanoi
To recurse, or not to recurse, that is the question.
77 days old.
Musical Score
Teach your computer to read music.
113 days old.
Roman to Decimal
Lazy Cows Don't Moo.
145 days old.
Bob Ross' The Joy of ASCII Art
Forget mountains, the future is ASCII Art.
168 days old.
Polynomial Division
Because algebra is fun!
173 days old.

Active Challenges [View All]

99 Bottles Of Beer
Does your code sing?
55 entries in the last seven days.
Pascal's Triangle
Not-very-geometric arrangement of the binomial coefficients in a sort-of-triangle.
24 entries in the last seven days.
Home On The Range
It's as simple as "1 2 3 5 6 8" => "1-3, 5-6, 8."
22 entries in the last seven days.
Bob Ross' The Joy of ASCII Art
Forget mountains, the future is ASCII Art.
20 entries in the last seven days.
Prime Factors
Work out the prime factors of a given number.
15 entries in the last seven days.