# The Grey Labyrinth is a collection of puzzles, riddles, mind games, paradoxes and other intellectually challenging diversions. Related topics: puzzle games, logic puzzles, lateral thinking puzzles, philosophy, mind benders, brain teasers, word problems, conundrums, 3d puzzles, spatial reasoning, intelligence tests, mathematical diversions, paradoxes, physics problems, reasoning, math, science.

Message body

 Emoticons View more Emoticons
Options
HTML is OFF
BBCode is ON
Smilies are ON
 Disable BBCode in this post Disable Smilies in this post

 All times are GMT
 Jump to: Select a forum Puzzles and Games----------------Grey Labyrinth PuzzlesVisitor Submitted PuzzlesVisitor GamesMafia Games Miscellaneous----------------Off-TopicVisitor Submitted NewsScience, Art, and CulturePoll Tournaments Administration----------------Grey Labyrinth NewsFeature Requests / Site Problems
 Topic review
Author Message
wordcross
Posted: Mon Apr 13, 2009 2:45 am    Post subject: 1

no problem
MTGAP
Posted: Mon Apr 13, 2009 12:57 am    Post subject: 0

wordcross wrote:
quicksort shouldn't be limited to arrays of a set size. If done correctly it should use recursion to repeatedly halve whatever array you throw at it.

Ah... I was under the impression that quicksort wasn't working because I was inputting the array as being one longer than it actually was, so it was trying to access a nonexistent memory address. Great.

It works now. Thanks for the help.
wordcross
Posted: Sun Apr 12, 2009 11:45 pm    Post subject: -1

quicksort shouldn't be limited to arrays of a set size. If done correctly it should use recursion to repeatedly halve whatever array you throw at it.
MTGAP
Posted: Sun Apr 12, 2009 11:12 pm    Post subject: -2

I am trying to write a program that requires the sorting of a list that contains about 50,000 elements, and I need an efficient sorting algorithm. I was going to use the Quicksort http://linux.wku.edu/~lamonml/algor/sort/quick.html algorithm, but I think it only works if the array of elements contains only numbers from 1 to <number of elements>, which is not the case for my program. I need an efficient algorithm that sorts an array containing any numbers, and it needs to be efficient for sorting 50,000 elements and at the same time not use up all my computer's memory. I am currently using the Shell http://linux.wku.edu/~lamonml/algor/sort/shell.html algorithm, but it seems awfully slow.[/url]