Google codejam questions do not need much knowledge, but they do need very crisp thinking, and an ability to write correct code quickly. Debugging solutions during a code-jam round is very stressful, and best avoided by getting the code right first time.
Practice on the past Google code-jam problems. Practice on the Project Euler problems (344 of them, enough for two years or more...). Even more important, when you have a solution - or you have to give up after a serious attempt - read the analysis and read some solutions from some of the top solvers. Their brains are amazing, their answers can be very neat and tidy. Then go away, sleep, come back next day, and answer the same question again using your new knowledge. And repeat until you too can produce a neat answer quickly. This last step is most important (and tedious) in the learning process, though also skipped too often. If a question gives trouble, say to yourself - "It is only a Google code jam problem, it can't be that hard!". And then write down a list of possible approaches and strategies that might work. And try again. At some point you have to look at some texts on algorithms to get a few ideas and knowledge on: - sorting algorithms - priority queues - standard graph algorithms (spanning trees, shortest path to one point, shortest path between all pairs of points) - transitive closure - data structures for associative arrays - max flow/min cut for a flow in a graph and ensure you recognize the concepts: - dynamic programming - divide and conquer - depth first search - breadth first search and probably much more. My thought is that Java and C++ are more convenient than C because they provide a richer library for handling arrays, sets, strings, associative arrays, and such stuff. But it probably makes little difference. -- You received this message because you are subscribed to the Google Groups "google-codejam" group. To post to this group, send email to [email protected]. To unsubscribe from this group, send email to [email protected]. For more options, visit this group at http://groups.google.com/group/google-code?hl=en.
