"Demystification" is just as important as "Abstraction" in "Computer Science" (Was: Know any Fortran
Fred Cisin
cisin at xenosoft.com
Fri Oct 30 15:40:58 CDT 2015
On Fri, 30 Oct 2015, Guy Sotomayor wrote:
> Him: I allocate an array of structures and I read them off of disk into the array.
> Me: How big are the structures?
> Him: About 4K
> Me: How many are you allocating?
> Him: 100,000
> Me: Rolls eyes. That’s 4GB. We don’t have 4GB on the embedded platform. You don’t even have that on your workstation.
> Him: But it works there and not on the embedded platform.
> Me: We don’t have paging turned on in the embedded platform.
> Him: Can’t we turn it on? It makes my code so simple!
> . . .
> I still think a 3 tape sort should be a required early assignment (learn that not everything can fit into memory at once).
I struggled with that for 30 years.
Third semester programming students in Data Structures and Algorithms
classes still insisted on trying to load the whole file into memory.
Even in the simplistic example that I gave them of a business appending a
record to an already sorted file and then sorting it, when they should
have sorted just the appended records and then done a two file input, one
file output merge, with only two records in memory at a time.
I always assigned them a problem of writing a sort for a file/dataset too
big to fit into memory. They literally refused to understand that a
dataset could exist that would be too large to fit into memory.
A couple of students wrote a letter to the college
administration complaining about me and the department and our
"out-dated" curriculum, insisting that "in the real world, the proper
solution to a file too big for memory is to replace the computer with a
bigger one." I was actually called on the carpet to answer the charge!
That was trivially easy when I pointed out to the chancellor how much it
would COST to equip the student homework computer labs with computers
capable of holding a national telephone directory in memory.
Our industry is saturated with such refusal to understand. Consider
Microsoft's "throw hardware at the software problems" argument that if
their software runs too slowly on your computer, then that shows that YOUR
COMPUTER (and you) is inadequate, and you should get a faster computer.
--
Grumpy Ol' Fred cisin at xenosoft.com
More information about the cctech
mailing list