The Artima Developer Community
Sponsored Link

Weblogs Forum
Python in Google Code Jam

7 replies on 1 page. Most recent reply: Aug 15, 2006 8:54 PM by Jia Kan

Welcome Guest
  Sign In

Go back to the topic listing  Back to Topic List Click to reply to this topic  Reply to this Topic Click to search messages in this forum  Search Forum Click for a threaded view of the topic  Threaded View   
Previous Topic   Next Topic
Flat View: This topic has 7 replies on 1 page
Guido van van Rossum

Posts: 359
Nickname: guido
Registered: Apr, 2003

Python in Google Code Jam (View in Weblogs)
Posted: Aug 14, 2006 8:50 AM
Reply to this message Reply
Summary
Python is now an approved language in Google's yearly Code Jam coding contest.
Advertisement

For a number of years, Google has run a yearly coding contest named Code Jam. The smartest (young) programmers in the world compete against each other for prizes and fame.

There are 3 online rounds (September 5-6, September 14 and September 19). The top 100 will be invited for the final coding showdown at Google New York on October 27, 2006. All travel and accommodation expenses will be covered by Google and there will be over $165,000 in cash and prizes.

What's most exciting for me is that this year, for the first time, Python is one of the supported languages. (The others are C++, Java, C# and VB.NET.) I'm hoping that at least some of the finalists will get that far by exploiting Python's superior coding speed!

(Googlers, others involved in setting up the competition, and their families, etc., etc., are not allowed to participate, as is customary in such things.)


rubyfan

Posts: 22
Nickname: rubyfan
Registered: Jan, 2004

Re: Python in Google Code Jam Posted: Aug 14, 2006 5:22 PM
Reply to this message Reply
I'm surprised that there is _any_ limits on the language that can be used in the CodeJam. If they're going to allow VB.Net, then it would seem that they could include other fine languages like Scheme, Ruby, Smalltalk, OCaml and Haskell. Really, it seems like you should be able to use whatever language you like.

Siddharta Govindaraj

Posts: 1
Nickname: siddhi
Registered: Aug, 2006

Re: Python in Google Code Jam Posted: Aug 15, 2006 6:11 AM
Reply to this message Reply
I was pretty excited too, until I saw:

> NOTE: All submissions have a maximum of 2 seconds of runtime
> per test case. This limit is used in harder problems to
> force submissions to be of a certain complexity. Because of
> the inherent speed differences between Python and the other
> offered languages is large, some problems may require extra
> optimization or not be solvable using the Python language.

Jonathan Ellis

Posts: 7
Nickname: jbellis
Registered: Aug, 2005

Re: Python in Google Code Jam Posted: Aug 15, 2006 6:52 AM
Reply to this message Reply
Because topcoder has an automated testing component that needs to hook into contestants' code.

(VB.NET is easy because it and C# obviously both compile to the same IL, so if you support one you pretty much get the other for free.)

Luis Sergio Oliveira

Posts: 22
Nickname: euluis
Registered: Jan, 2004

Re: Python in Google Code Jam Posted: Aug 15, 2006 7:42 AM
Reply to this message Reply
> (VB.NET is easy because it and C# obviously both compile
> to the same IL, so if you support one you pretty much get
> the other for free.)

Well, you have IronPython to enable Python in .Net... Isn't it compilable also to IL?

Guido van van Rossum

Posts: 359
Nickname: guido
Registered: Apr, 2003

Re: Python in Google Code Jam Posted: Aug 15, 2006 8:18 AM
Reply to this message Reply
> I was pretty excited too, until I saw:
> [Python disclaimer]

Yes, that's unfortunate. The time limit is because the kind of problems they tend to present have "lazy" solutions (like exhaustive search) as well as "smart" ones (where some mathematical analysis helps you to vastly reduce the complexity of the algorithm). The time limit is there to force you to come up with the smart algorithm. Now if all the problems were O(N) or even O(log N) that wouldn't be a problem for Python, but there are some problems (or so I've heard) where the best solution is still O(N**2), and then the compiled languages are in an obvious advantage. Your best bet is to know two languages -- Python for the O(log N) problems, and C++ or Java for the O(N**2) problems. Once we have winners we'll see how well this worked out.

(Sorry, even with IronPython vs. C#, C# has the advantage -- the compilation from Python to IL doesn't magically remove Python's dynamic typing, so it doesn't help enough -- Jim Hugunin has shown modest speedups compared to CPython, largely due to .NET's JIT, but generally not even 2x for realistic code.)

Guido van van Rossum

Posts: 359
Nickname: guido
Registered: Apr, 2003

Re: Python in Google Code Jam Posted: Aug 15, 2006 10:18 AM
Reply to this message Reply
[I tried to reply to this yesterday but Artima hiccupped.]

[Rubyfan]
> I'm surprised that there is _any_ limits on the language
> that can be used in the CodeJam.

The contest is actually run for Google by a contracting company, TopCoder.

For each language to support they have to do some work, such as creating a 100% foolproof language-specific test framework, and of course experts to judge the submissions (most of it is automated, but you've got to catch cheats manually). They do this for other companies to, which is probably how C# and VB.net came into the mix.

Google specifically contracted TopCoder to support Python since that is the #3 language at Google (C++ and Java are #1 and #2). Ruby and the other languages you mention are barely on Google's radar, for various reasons such as not having to support too many languages that fit the same niche.

Another way to look at this: given Google's investment in Python (which started long before I joined!), Google is more interested in people with Python skills than people with Ruby skills, all else being equal.

Jia Kan

Posts: 1
Nickname: kernel1983
Registered: Aug, 2006

Re: Python in Google Code Jam Posted: Aug 15, 2006 8:54 PM
Reply to this message Reply
Hello,I'm a pythoner from China.
Last year I was try to CodeJam 2005 when I was still a student in the school.But in fact,I'm not familiar with any language except Python.

Unlucky,I missed last changce to submit the code in C++ because of my overhead sleeping.

This year I will try again in Python.I'm sure I can at least finish it.

I'm very excited as yooou!!!!

Flat View: This topic has 7 replies on 1 page
Topic: Python in Google Code Jam Previous Topic   Next Topic Topic: Simplicity: Subtle, and not Easy

Sponsored Links



Google
  Web Artima.com   

Copyright © 1996-2019 Artima, Inc. All Rights Reserved. - Privacy Policy - Terms of Use