Pablo Manalastas <[EMAIL PROTECTED]> writes: > For my CS135 class at U.P., I gave a programming > assignment to compare the performance of quicksort, > heapsort, mergesort, and radixsort, on arrays of > strings. Each string is of fixed size 16 characters, > and the sort must be done on arrays of sizes 100000, > 200000, 300000, ... , 900000, 1000000. The students > are free to choose the operating system, and the > programming language. I showed the class that the > programming assignment can be done with Debian on 1GB > ram, using Gnu C, by giving the class a demo of > quicksort of the array of one million 16-character > strings. > > Among the problems that my students encountered and > reported to me are the following: > > 1. You can not do the programming assignment on > Windows, since the Windows development environment can > not support such big arrays. > > 2. You can not do the programming assignment using > Java on Linux, since Java-for-Linux does not support > such big arrays.
Not raw arrays as such, but what prevents you from using, say, an java.util.ArrayList? Or a java.util.Vector? Or, in fact, encapsulate the whole data structure operated on into a class and pass the sort method as a functor? > So the students are forced to use Linux, using C, C++ > or any tool that allows management of large arrays. > Unconsciously, I gave a programming assignment that > promoted the use of Linux, and extolled the virtues of > Linux, without making the advertisement so obvious. Sure, but again, I could probably do it in Java on any platform. I'm in fact tempted to write a quick one-off to demonstrate... :P (Caveat: I'm a programmer doing lots of Java, with a love-hate relationship with the language. My primary development environment is JDEE on Emacs on a Linux system.) -- JM Ibanez Software Architect Orange & Bronze Software Labs, Ltd. Co. [EMAIL PROTECTED] http://software.orangeandbronze.com/ _________________________________________________ Philippine Linux Users' Group (PLUG) Mailing List [email protected] (#PLUG @ irc.free.net.ph) Read the Guidelines: http://linux.org.ph/lists Searchable Archives: http://archives.free.net.ph

