Wow. This kind of craziness is exactly why I love the daily WTF. Thank you, NorseLaQuet, for providing some of the most ridiculous statements I've read in a while (since the last zzo post, in fact.)
You sound like a seriously scared data entry clert, threatened by the idea that someone might take the 0-based indexes away, thereby making your skills obsolete, since the compiler can do the task of translating from logical addresses to physical memory much better, faster and with greater reliability.
Why are you so stuck on this notion that you need to write code the way the computer expects it? Have you never seen any functional languages? Of course, there is a need for some (absolutely tiny amount of) hardware level code, but those have fortunately become very specialized areas. Why aren't you rebeling against the C++ language and coding in assembly instead?
For comparison (not a very fair one, I'll grant you that,) here's a common algorithm implemented in C and in Haskell.
3.1 Quicksort in Haskell
qsort [] = []
qsort (x:xs) = qsort (filter (< x) xs) ++ [x] ++ qsort (filter (>= x) xs)
3.2 Quicksort in C
void qsort(int a[], int lo, int hi) {
{
int h, l, p, t;
if (lo < hi) {
l = lo;
h = hi;
p = a[hi];
do {
while ((l < h) && (a[l] <= p))
l = l+1;
while ((h > l) && (a[h] >= p))
h = h-1;
if (l < h) {
t = a[l];
a[l] = a[h];
a[h] = t;
}
} while (l < h);
t = a[l];
a[l] = a[hi];
a[hi] = t;
qsort( a, lo, l-1 );
qsort( a, l+1, hi );
}
}
Notice a difference? Bingo. The C code is all worried about mundane tasks, where to store items, how items are indexed and other "pointless" work that's only taking time away from thinking about *what* it is that you want the program to do. Here's some more information on the examples and the Haskell language: http://www.haskell.org/haskellwiki/Introduction#Quicksort_in_Haskell
@NorseLaQuet said:
I think you have a very shitty attitude to say that only 0.1% programmers are as smart as you.
That actually was a generalization and not a statement about his abilities. I think that anyone with a CS degree should have a decent understanding of those areas though. Everything mentioned was covered in various compiler design, operating systems and CPU architecture lectures offered at my university. Knowing how this works is no justification for actually developing software in backwards low-level ways, however. Understand it, and move on to high level languages that don't make you deal with all the crap that goes on during compilation / interpretation / execution of code, such as calculating array indexes.