Important Algorithms that are required for Online Programming Contests like ACM ICPC,Google Code Jam etc,.?
-
I have gone through this question . But what I have noticed here is, some mentioned quick sort and some sorting algorithms also. But as I'm using STL, I don't think they are important in progrmming contests point of view. :-P. So I want to know about those algorithms which are considered to be the best for various basic operations like matrix multiplication etc,. I'm looking forward for that answer which could give the list of best chosen algorithms for various operations not the elaboration of those topics.
-
Answer:
You seem to have a pretty specific idea of what you're looking for. What's the problem with looking up the algorithms you want for particular "operations" you're looking for yourself, without making people on Quora to guess which "operations" are on your list and which are not? For example, for matrix multiplication, go to Wikipedia article on the topic, et viola - http://en.wikipedia.org/wiki/Matrix_multiplication#Algorithms_for_efficient_matrix_multiplication, it's already there. Go through TopCoder tutorials, they have a lot of basic contest-specific algorithms. Learn to use fishing rod, not to ask people for fish, it's going to be useful in contests as well.
Mariya Mykhailova at Quora Visit the source
Other answers
It seems that you are completely missing point in learning algorithms and data structures. Learning algorithm is less about writing implementation and more about understanding ideas and insights that algorithm represents. Yes, having already written quicksort implementation in STL may help you sort vector without too much hassle. But not learning quicksort and others important sorting algorithms you are missing several important ideas behind them, and without those ideas you cannot solve some contest problems. That's why there is no "best and only sort algorithm you should know" - each of them will teach you different approaches and ideas which help you solve more complex problems later on.If you still think that having function sort() in STL is good enough for you, allow me to demonstrate what extactly you are missing. There is list of several question, problems and ideas that learning about sort algorithms and sorting in general helps you answer and master (and if we will not think only about programming contest there will be many more such as external sorting, parallel sorting and so on...). is sort() is stable? How to fix it? what properties should satisfy comporator for sort() ? bonus point: what would be result of supplying sort() with comporator which do not satisfy these properties? in what cases sort() is ineffective? bonus point: prove that any sorting algorithm which relied only on comporator with aforementioned properties would be ineffective in these cases bonus point: provide example of sorting algorithm which would be more effective than sort(). Explain why despite previous bonus point that algorithm is faster than any possible implementation of sort() algorithm for kth order statistic bonus point: prove complexity of that algorithm "divide and conquer" approach priority queue bonus point: improve Dijkstra algorithm with it determine number of https://en.wikipedia.org/wiki/Inversion_%28discrete_mathematics%29 in array merge sorting tree bonus point: usage of merge sorting tree for implementation of compressed range tree sort a lot of integers with values in range [math][0;1000][/math] effectively. bonus point: usage of somewhat similar algorithm for constructing suffix array
Karpichev Roman
Related Q & A:
- Are there any jobs online for teens like work at home jobs?Best solution by Yahoo! Answers
- Is there any GED school online that just like cyber school?Best solution by Yahoo! Answers
- Where can I take an online programming aptitude test/exam?Best solution by Stack Overflow
- Anyone been to Salvador in Brazil. What's it like - beaches, people, cost of hotels etc?Best solution by answers.yahoo.com
- What are some online photo contests?Best solution by ChaCha
Just Added Q & A:
- How many active mobile subscribers are there in China?Best solution by Quora
- How to find the right vacation?Best solution by bookit.com
- How To Make Your Own Primer?Best solution by thekrazycouponlady.com
- How do you get the domain & range?Best solution by ChaCha
- How do you open pop up blockers?Best solution by Yahoo! Answers
For every problem there is a solution! Proved by Solucija.
-
Got an issue and looking for advice?
-
Ask Solucija to search every corner of the Web for help.
-
Get workable solutions and helpful tips in a moment.
Just ask Solucija about an issue you face and immediately get a list of ready solutions, answers and tips from other Internet users. We always provide the most suitable and complete answer to your question at the top, along with a few good alternatives below.