"Andrea Griffini" wrote: > I think that if you don't understand memory, > addresses and allocation and deallocation, or > (roughly) how an hard disk works and what's > the difference between hard disks and RAM then > you're going to be a horrible programmer. > > There's no way you will remember what is O(n), > what O(1) and what is O(log(n)) among containers > unless you roughly understand how it works.
There's a crucial distinction between these two scenarios though: the first one has to do with today's hardware and software limitations while the second one expresses fundamental, independent of technology, algorithmic properties. In the not-too-far-future, the difference between RAM and hard disks may be less important than today; hard disks may be fast enough for most purposes, or the storage policy may be mainly decided by the OS, the compiler, the runtime system or a library instead of the programmer (similarly to memory management being increasingly based on garbage collection). As programmers today don't have to know or care much about register allocation, future programmers may not have to care about whether something is stored in memory or in disk. OTOH, an algorithm or problem with exponential complexity will always be intractable for sufficiently large input, no matter how fast processors become. The bottom line is that there is both fundamental and contemporary knowledge, and although one needs to be good at both at any given time, it's useful to distinguish between them. George -- http://mail.python.org/mailman/listinfo/python-list