The Apprentice

  • Ben Moorhouse

    SSCrazy

    Points: 2385

    Totally agree here!

    We recently had to build an SQL based application on a desktop for thousands of people to use.

    Whilst it wasn't the best start for a database (!!) it did mean that we had to really focus on the little bits that could squeeze just a tiny bit more performance out of it. So it's now a really efficient database running on two servers. 🙂

  • TomThomson

    SSC Guru

    Points: 104773

    Steve Jones - SSC Editor (9/12/2011)


    roger.plowman (9/12/2011)


    I keep seeing the chest-pounding developers who claim if you don't know how to implement low-level structures in C (or equally low-level languages) that you're not a real developer/CS degree holder/etc.

    Folks, it's been *decades* since I worried about low-level stuff. I'm too freaking busy creating applications by my lonesome to bother with sorting and memory management. That's what *frameworks* are for.

    I disagree with you for this reason. It seems that without being able to understand low level structures, and have an appreciation for how socket networking operates, pointers work, low level functions like copy, etc., I think you lose perspective for how to program efficiently.

    It's just my opinion, but it seems that so many people I've met who graduated post-Java era ('92 or so), don't really think about what is happening in their frameworks, or try to be efficient in their use of the higher level functions.

    I don't believe we need to go to assembler to teach this, nor do I think that we should have people specialize this if they aren't low level programmers, but I do think that having to do a semester of C will ground people in the basics of programming and development. After that, if they move to higher level frameworks, that's fine, and hopefully then they learn to think about the functions they use, look for efficient working functions from the machine's perspective.

    I believe, and I may be wrong, but too often is seems people take the shortest method for the programmer to solve a problem, which often ends up being the longer method for the machine and becomes a bottleneck.

    I agree that people should maintain some understanding of what's going on at a low level, and that if they don't they may lose sight of factors that have an impact on code performance.

    I don't however think that a semester of C will give people an understanding of these things, because C is a betwixt and between mess. It is indeed very low level, but it has high level pretensions. Maybe Knuth's artificial assembler language MIX (used in "The Art of Computer Programming") or the modern substitute MMIX would be better, or maybe Dijkstra's guarded command language (used in "A Discipline of Programming"); or perhaps an assembler for a real machine would be better. Or a language with sound pointers (Algol 68 or any of its children).

    I don't think the problem of people who have no regard for efficiency has anything to do with graduating in the post 92 era or with Java; we have had people like that for ever (or at least for four decades). I remember one guy who had a computation which involved calculating the determinants of some largish (25 row) matrices and tried to use a routine that did the job using the recursive descent method (add products of top row elements with the corresponding submatrices 1 smaller, with the recursion stopping at single row matrices where the determinant is just the single element; computational complexity O(N!)) and was very upset when the sysops thew it off the machine the first time it ran because it ran for too long. He spent ages trying to work out why it took so long, until someone who understood program efficience took a look at it and exploded with laughter. Nothing could be done to make him understand that the algorithm he had used was (a) hopelessly inefficient (so inefficient that on what was in 1971 a big computer would have taken at least a hundred billion years to invert just one of those matrices, let alone do the rest of the required computation) and (b) certain to maximise the effect of rounding errors, so that the results would be useless if it ever did terminate. Not even when someone else picked it up and wrote a version which used Gaussian elimination with pivot optimisation to semi-diagonalise and then took the product of the diagonal elements (complexity O(N^3), so about a sextillion [1,000,000,000,000,000,000,000] times as fast as recursive descent on that size matrix) and of course much more resistant to losing significance through rounding errors being compounded would he believe there was anything wrong with his way of doing it.accept that he should have looked at computational complexity before writing his program, let alone before wasting valuable machine time on it.

    Tom

  • Nadrek

    SSC-Insane

    Points: 20039

    Tom.Thomson (9/13/2011)


    Steve Jones - SSC Editor (9/12/2011)


    I agree that people should maintain some understanding of what's going on at a low level, and that if they don't they may lose sight of factors that have an impact on code performance.

    I don't however think that a semester of C will give people an understanding of these things, because C is a betwixt and between mess. It is indeed very low level, but it has high level pretensions. Maybe Knuth's artificial assembler language MIX (used in "The Art of Computer Programming") or the modern substitute MMIX would be better, or maybe Dijkstra's guarded command language (used in "A Discipline of Programming"); or perhaps an assembler for a real machine would be better. Or a language with sound pointers (Algol 68 or any of its children).

    Agreed; while learning some C should allow one to understand pointers, and hopefully that assigning a "type" to variables even in strictly typed languages is not enforced by the processor, C will not help one understand word/doubleword alignment, 2's complement, and bit shifting unless one looks for it deliberately.

    Forth is good for learning stacks, but a real assembler language is best... particularly one where a basic efficiency trick exists, such as always using a certain memory operation instead of the actual ADD to add 1... because it's faster.

    More importantly, I hope any Computer Science graduate learns several languages; the knowledge that all languages of a given type are roughly similar, and it's just a matter of syntax and convention to switch, is valuable in overcoming the "I don't know X (old|new) language!" response to giving someone either newer or older languages to maintain/use.

  • djackson 22568

    SSChampion

    Points: 11713

    roger.plowman (9/12/2011)


    I keep seeing the chest-pounding developers who claim if you don't know how to implement low-level structures in C (or equally low-level languages) that you're not a real developer/CS degree holder/etc.

    Folks, it's been *decades* since I worried about low-level stuff. I'm too freaking busy creating applications by my lonesome to bother with sorting and memory management. That's what *frameworks* are for. I assume that something like .Net (or the Java/C/C++ equvilents) are written by teams of specialists who *of course* are expert in the low-level things like memory management and efficient sorting and all the minutiae that go on behind the scenes. They can wring that last CPU cycle from an algorythm and have spent their careers doing exactly that.

    Hmmm. So, you are comfortable with the quality of MFC? Those developers didn't even know how to use their own product and ended up leaking memory worse than anything I have seen.

    Why does my background help me? Because when I NEED to write better code than the framework I am using I CAN. Do I do it all the time, no, but that isn't the point.

    Those who only program at a high level are not necessarily inferior. You might very well be twice the programmer I am. But I believe it is true to say that those who understand the low level are far more often more capable. Most of the serious, long outstanding bugs I have seen were written by people who although very intelligent, had no base knowledge, and therefore didn't have a clue where to look. One prominent one I recall existed for almost two years, I found it in 15 minutes. Others had spent months looking for it.

    Today I do most of my work at a high level, but I truly believe I am better for my experience.

    Dave

  • Thomas-282729

    Say Hey Kid

    Points: 663

    My experience has been that CS majors learn more about how compilers, sorting algorithms and computers work than how make effective use of them. The CS majors with whom I've worked were incompetent with respect to requirements gathering and understanding business needs. They were great at building stuff; just not the stuff that users want or need. CS majors tend not to understand the problem domain whether that be the fundamentals of business, the nature of a particular business or the science that is the target of the software project. Interestingly, the only two CS majors in my 25+ years of experience that were good at these tasks doubled in liberal arts studies of various sorts (one music, the other theatre).

    Take databases for example. Relational databases are fundamentally set focused. The vast majority of development languages learned in colleges are iterative focused (run things in loops). Most application developers tend to be poor at database design and many database designers are poor at middle-tier and interface design. Rarely is it the case that CS majors are good at both application development and database development.

    All of this should be met with the caveat that my experience is based on what I've seen from people with whom I've worked, hiring candidates and when I was in college (I was not a CS major but had a couple of friends that were). Perhaps that is starting to change but until then, what matters is what the person has done (i.e. experience) far more than a degree.

Viewing 5 posts - 91 through 95 (of 95 total)

You must be logged in to reply to this topic. Login to reply