In the competition like Google Code Jam the language is just a tool to implement your algorithms and ideas of solving the problem. So you should select the tool you are most comfortable with. The main job for the participant is to come up with a correct and efficient algorithm for solving the problem. And I'm almost sure that every problem from this competition can be solved with any programming or scripting language if you are using the efficient algorithm. Many people use C++ because they feel comfortable with it, mostly because they learned C++ at school or college and used it a lot in the programming competitions like this. The other reason is that if you are a fun of programming competitions like Code Jam, C++ would be a good choice, because it can be used in all such competitions, while the other languages, like scripting languages, are not always allowed. For example the two most popular programming competitions ACM ICPC and TopCoder both allow you to use C++ and Java to participate.
On Sep 5, 2:37 am, vgbhat <vgb...@gmail.com> wrote: > Interesting comments from fellow code-jammers! I too agree that this > is about data structures and algorithms. For the Problem A, initially > I was thinking too much, and then, suddenly realized that simple regex > in perl will do the trick (although, the perl script I have written is > not that efficient). For Problem C, I couldn't understand the > algorithm to solve it. I tried basic nested loops, and it runs forever > to finish the job :-) > > Another point to make: Observed that most people coded in C++/Java > compared to scripting languages (like PHP/PERL). Could it be because > of their choice, or scripting languages have some limitations while > solving complex alrogithmic problems? > > Best wishes, > vgbhat > > On Sep 4, 1:00 pm, quasar <quasar.aruno...@gmail.com> wrote: > > > I have the same feeling! Codejam is an algorithmic contest! so learn > > new techniques for solving problems. > > > Cheers > > > On Sep 4, 12:06 pm, vexorian <vexor...@gmail.com> wrote: > > > > 1. Always try new languages and techniques, just don't do it during a > > > match. > > > 2. Yes, with time I learned to have a .sh script to easily run .cpp > > > files and it has a "valgrind" argument that will make it run them with > > > valgrind. The editor I use, geany is tweaked the way I like. > > > 3. If by hardcode you mean storing stuff in the source files > > > themselves, then yes. If you are talking about not using constants, I > > > disagree. I think constants and making things easy to modify are very > > > helpful. It's been many times that I lost 2 minutes changing a wrong > > > constant when I didn't follow this tip. > > > 4. C++ wins :) Of course, just use the language you are most > > > comfortable with, in the case of codejam, things like the language's > > > speed are not important. Personally, I can't picture myself doing one > > > of these contests without my beloved STL. > > > 5. The fastest solution for A did not use regexes. I am fairly sure > > > that trying to hack regexes was slower to code and come up to than > > > just doing the (easy) bruteforce method. I am yet to actually solve > > > something with regular expressions during an actual contest. But it > > > does not harm to know many tricks. > > > 6. Practice is really the only answer. > > > > On Sep 4, 11:26 am, Satyajit Malugu <malugu.satya...@gmail.com> wrote: > > > > > ---------- Forwarded message ---------- > > > > From: Prolific Coder <prolific.co...@gmail.com> > > > > Date: Fri, Sep 4, 2009 at 11:25 AM > > > > Subject: Competency levels > > > > To: google-code@googlegroups.com > > > > > I do programming for a living and I think I am not bad. I have been in > > > > programming interviews before and could solve 90% of questions. > > > > But this is different, I mean I am reading questions and deciding which > > > > one > > > > to solve and TADA, I see solutions being submitted! I felt so bad > > > > and incompetent. Are others that good? Or worse am I that bad? > > > > > But alas, I took minimum of 5 hours to solve the first problem. And I > > > > know > > > > that if I don't change my methodology or practise I will not move > > > > forward. I > > > > want to give it my best shot and since I have a long weekend try to > > > > practice > > > > as much as I can. > > > > > Can you guys share the techniques or the mind set for solving the > > > > problems > > > > fastly? > > > > > Some of things I observed so far. > > > > > 1. Don't try new languages or techniques. > > > > 2. Already have your IDE and language,debugger and scaffolding setup. > > > > 3. Its OK to hardcode > > > > 4. cpp is the language of choice ( but I don't agree like many > > > > others) > > > > 5. Practice regex's you have to become damn good at them. > > > > 6. Practice, practice and more practice > > > > > -- > > > > Satyajit --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "google-codejam" group. To post to this group, send email to google-code@googlegroups.com To unsubscribe from this group, send email to google-code+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-code?hl=en -~----------~----~----~----~------~----~------~--~---