How would you sort 1 million 32-bit integers in 2MB of RAM?
Please, provide code examples in a language of your choice. Update : No constraints set on external storage. Example: Integers are received/sent via network. There is a sufficient space on local disk for intermediate results. Split the problem into pieces small enough to fit into available memory, then use merge sort to combine them. Sorting a million 32-bit integers in 2MB of RAM using Python by Guido van Rossum 1 million 32-bit integers = 4 MB of memory. You should sort them using some algorithm that uses external storage. Mergesort, for example. You need to provide more information. What