Want to read Slashdot from your mobile device? Point it at m.slashdot.org and keep reading!

 



Forgot your password?
typodupeerror
×
Programming IT Technology

Software Aesthetics 748

cconnell writes: "Most software design is lousy. Most software is so bad, in fact, that if it were a bridge, no one in his or her right mind would walk across it. If it were a house, we would be afraid to enter. The only reason we (software engineers) get away with this scam is the general public cannot see inside of software systems. If software design were as visible as a bridge or house, we would be hiding our heads in shame. This article is a challenge to engineers, managers, executives and software users (which is everyone) to raise our standards about software. We should expect the same level of quality and performance in software we demand in physical construction. Instead of trying to create software that works in a minimal sense, we should be creating software that has internal beauty." We had a good discussion on a related topic half a year ago.
This discussion has been archived. No new comments can be posted.

Software Aesthetics

Comments Filter:
  • blah (Score:2, Insightful)

    by teknopurge ( 199509 ) on Tuesday September 04, 2001 @04:51PM (#2252807) Homepage
    The reason it's so bad is because it doesn't have to be good to get the job done. Most management is just about getting things done fast.

    There is usually a tradeoff between quality and expediancy.

    teknopurge

    http://techienews.utropicmedia.com [utropicmedia.com]. help us beta.
  • by GusherJizmac ( 80976 ) on Tuesday September 04, 2001 @04:54PM (#2252817) Homepage
    Software has to:
    1. Meet user requirements
    Which doesn't necessarily mean it has nice and pretty code. If you have time, you are doing yourself a favor by designing it, but you can't lose track of the purpose of what you are doing, which is to get something working.

    Most techniques for designing or building software (e.g. patterns, processes) all serve to help you avoid bugs, which is to say more efficiently build software that meets user requirements.

  • by Anonymous Coward on Tuesday September 04, 2001 @04:55PM (#2252823)
    Actually, it is amazingly elegant and well thought out--(maybe "thought" is too strong).

    Organisms are incredibly adept at reusing design and building specialized components from generic building blocks.

    They just happens to ooze.
  • by FortKnox ( 169099 ) on Tuesday September 04, 2001 @04:56PM (#2252832) Homepage Journal
    I've found that most of the cause of the problem is people "whip out a function that does that job" so they can compile the program, then never go back and fix it up.
    Same with code comments. "I'll add good comments later/when I'm done", and you finally get the program stable when it needs to be released.

    I find it a ton easier to do everything the way you were taught in software engineering 101. Design the hell outta documents (I, personally, use RUP which I find nice), then code complete objects, nothing that'll just "let me compile", but whole objects. *AND* I'll code in the javadoc when I make the object. The code comes out quit nice that way.
  • And How!!! (Score:4, Insightful)

    by Telek ( 410366 ) on Tuesday September 04, 2001 @05:01PM (#2252862) Homepage
    I can't tell you how many software packages I've looked at that are ABSOLUTELY HIDEOUS on the inside (and open source isn't exactly immune to that either. Anyone taken a look at the code of SSLeay? Good package thou).

    The problem being, however, that once you have money entering the picture, and/or time, then the first thing to go is code quality. Mind you, combine that with the fact that a few years ago anyone who had the patience to sit down and read "How to program in java in 21 days" suddenly became a programmer. Here at work we have a very large codebase that we originally contracted out someone else to do, then took over once we got more funding. They preferred the "copy/paste" approach to doing loops, and tonnes of other hideous hideous things. I've done things like cut down 2500 lines of code to 1100. In fact, the company here could save money in the long run by hiring me to do nothing but optimize, by the cost of additional hardware that they would have had to buy to support this. ugh.

    Unfortunately, in the land of "80% complete is good enough" and where "as long as it works" is a good philosophy, and in a land where "visual basic" is a professional programming language, we're not going to see this improve any time soon. Even Java works squarely against the goal of "efficient". Give me C++ any day.

    I think that another part of the problem is people just not caring about their code, not having pride in what they accomplish. That and people simply not knowing what the hell they're doing. (Not that I know ANYONE like that around here... nope nobody...)

    Argh. Ok sorry, I'll end my rant now.
  • flawed analogy (Score:4, Insightful)

    by funkapus ( 80229 ) on Tuesday September 04, 2001 @05:02PM (#2252874) Homepage
    Typically, the user interface to software is supposed to look good. This corresponds to the visible stuff in a house: the walls, floor, fixtures, etc.

    But does the wiring look pretty? Or the plumbing? Or the unfinished basement/garage? Or any of the stuff that actually makes the house work?

    Hell no.

    Does the engine of a car look pretty? It's covered in grease and all kinds of crap is sticking every which way, and it doesn't make sense to the non-initiated. Function is more important than form when it comes to making the car go.

    I'm getting tired of these calls for purty code. I like an elegant piece of software as much as the next guy, but my manager could give a crap as long as it works, and in fact won't be willing to give me extra weeks to make it look nice on the inside. Particularly when you consider that I'm probably the only person who's really ever going to look at my code.
  • by Flabdabb Hubbard ( 264583 ) on Tuesday September 04, 2001 @05:03PM (#2252879) Homepage Journal
    to recognize the artistry involved in writing software

    What pretentious bullshit. Software is NOT art. It can be closely compared to bricklaying, or cabinet making, it is a CRAFT.

    Try expressing an emotion in C++. It cannot be done. Please think before repeating these banal opinions that software is art. It just isn't. Deal with it, and if you want to be an artist, learn to paint.

  • by whjwhj ( 243426 ) on Tuesday September 04, 2001 @05:06PM (#2252901)
    Attempting to compare software engineering to building a bridge or constructing a house is flawed. The reason bridges are built to such exacting standards is because if they aren't, they FALL DOWN. They cease to function. 100% failure. Poorly built software, on the other hand, can still work well enough to be usuable. It may imperfect at some tasks, but perform adaquately at others. If it were true that anything less than a perfectly engineered piece of software would simply fail to compile, then we'd all be writing perfectly engineered software.

    An additional flaw in the analogy is this: The function, or use, of a bridge is quite clear: Extend a roadway over an otherwise impassable divide, such as a river. Simple as that. But deciding what the function or use of a piece of software is much more difficult and complex. Software is told to do many things, and the things it's supposed to do changes over time.

    I'm all in favor of well designed software. But his vision is more utopian than useful.
  • Code aesthetics (Score:2, Insightful)

    by KingAzzy ( 320268 ) on Tuesday September 04, 2001 @05:08PM (#2252919)
    There is a definite difference between a "Programmer" and a "Coder". Programmers are interested in the aesthetics of their engineering as well as the science behind it (the two are non-distinguishable) whereas Coders only care about getting the job done well enough so that they continue to have employment and not get fired.

    Programmers are much more expensive than coders and harder, much harder, to find for employment. Coders are very abundant. I have never seen a development department (in the 'big corporate IT world') that had more than just a small handful of true programmers, yet dozens and dozens of coders all whittling away at these massively bloated, poorly designed, inefficient, unscalable, pieces of pure SHIT that absord millions and millions of dollars from the corporate budgets.

    I don't think comparing houses and bridges to pieces of software is a very fair comparison, btw.. In construction it's quite easy to put lower skilled people to work effectively for the larger picture (doesn't take much as much skill to lay brick as it does to design the wall) than it does in coding (an inexperienced coder can virtually infect the entire project with his or her incompetence.

    These are my opinions after working in big IT for too long and perhaps after reading too much Dilbert and Slashdot.
  • by tomlouie ( 264519 ) on Tuesday September 04, 2001 @05:08PM (#2252920)
    Hastily written code that's intended to be only a "temporary" fix never seems to be replaced with working code. The problem is that the "temporary" code isn't visibly different from more permanent code.

    The building analogy is that anyone can spot a poorly put together shack, as opposed to a carefully poured concrete foundation. Not so easy with code.
  • XP! (Score:4, Insightful)

    by Proud Geek ( 260376 ) on Tuesday September 04, 2001 @05:10PM (#2252936) Homepage Journal
    That is why we have advanced software engineering techniques like eXtreme Programming. Through it's constant refactoring it makes sure that code is always the best it can be for the task at hand, and constantly improving.

    The only reason that so much code is ugly is that most people do not know about and adopt XP. XP closely resembles the reality of Open Source programming in its implement-now mentality and constant addition of features. If everyone used XP, the software world would be a better place!
  • by servo8 ( 572 ) on Tuesday September 04, 2001 @05:10PM (#2252939)
    I think a problem here is getting to a common definition of art. If a master craftsman pours his soul into a work, how is that not art? Just because the emotions a work may convey cannot be easily categorized and labelled does not mean they are not valid feelings. There are many pieces of "craftsmanship" out there that evoke such feelings. I have felt them myself. Would you deny me that?
  • by tim_maroney ( 239442 ) on Tuesday September 04, 2001 @05:11PM (#2252954) Homepage
    Every extra day that I take to plan, every minute I spend thinking about design, and every extra line of code I write to make my software more pleasing is another line that could add more functionality, another minute wasted not producing something tangible, and another day that I need to be paid.

    That is an absolutely absurd statement. Every moment spent in planning, review, consideration of potential problems, creation of general-purpose solutions, and documentation of architecture pays for itself many times over later in the development, validation, release and maintenance cycles. Failure to undertake sensible planning activities early in a project leads to massive schedule delays from forced late-game rearchitectures that would have been headed off by early consideration, review and communication.

    Software engineering is the only engineering discipline in which the practitioners are permitted to indulge themselves in work without planning or review, and that's the #1 reason that software sucks.

    Tim
  • Bad analogy. (Score:2, Insightful)

    by Dasein ( 6110 ) <tedc@codebig. c o m> on Tuesday September 04, 2001 @05:12PM (#2252958) Homepage Journal
    Building software and physical structures are two entirely different things:

    1) The customer of a construction company is unlikely to decide that their cute split-level should now be a super mall after construction is underway. It isn't unusual to see the equivalent happen in software.

    2) The "Mythical Man Month" presents a pretty good argument about fundamental complexity Vs. accidental complexity. It would be a good thing to think about.

    3) Because everyone has a passing familiarity with the physical world things that aren't right get pointed out fairly quickly. In my experience is that about 20-30% of programmers can cut through the symptoms and treat the cause. Everybody else goes around plastering over cracks instead of realizing that the foundation is crumbling.

    My two cents.
  • Specs Sucks! (Score:1, Insightful)

    by Anonymous Coward on Tuesday September 04, 2001 @05:12PM (#2252966)
    I'll start writing code as beautiful as a bridge when management stops changing the requirements throughout the programming process. How many bridges do you think would look good and be stable if half way through the construction one person decided it needed three more lanes, another felt it should be double decked and yet another added the requirement that it be one way. Software sucks 90% of the time because the requirement specs suck. And no one every looks at a bridge that is 70% complete and says "This looks good enough for now, let's start using it and work out the kinks as we go" like they with software.

    I agree, most code look horrible and is a terrible mess, but that is a side effect of external forces, not because programmers need to be inspired to write clean beautiful code by some article.
  • by Anonymous Coward on Tuesday September 04, 2001 @05:20PM (#2253011)
    manager -> we need to ship this bridge in 3 months.
    engineer -> yes, but it's really big and really important
    manager -> yes, but it has to ship in 3 months.
    engineer -> so how much weight does it need to support?
    manager -> i dunno, I'll let you known in 2.9 months.
    engineer -> what is it bridging?
    manager -> why all these stupid questions, start building.
    engineer -> I should do an architectural drawing first.
    manager -> why bother, here's some metal, start slapping it together. Remember it ships in 2 months.
    engineer -> I thought you said 3 months?
    manager-> oh didn't I tell you, we heard a rumour that a competitor will be shipping their bridge in 2.5 months, so we have to beat them.

    continue forever.

    the reason there is no internal beauty is we (engineers) aren't given any time to build quality (although the argument could be made that the only way to build on schedule is by building quality). The other problem is, bugs actually translate into lucrative support contracts for most enterprise software vendors. Why improve quality? there is no revenue stream there. If users would SUE software development firms (the same way people would sue if a bridge fell when you drove on it) then vendors would suddenly find time in schedules for testing and quality.

    we do the best we can, given the pressures. My advice, try to learn to say "no" to your manager once in a while, and hire a QA manager with balls who won't let shitty software ship.

  • by Andrewkov ( 140579 ) on Tuesday September 04, 2001 @05:20PM (#2253012)
    This article is demeaning to programmers. The reason quality is poor is due to unrealistic deadlines, the reason projects are over budget is due to poor planning.

    Most good programmers are capable of creating high quality, elegant code, but are not allowed to because of external pressures that are out of their control.

    And with all due respect to engineers, most software is a lot more complicated than building a bridge.

  • by Glock27 ( 446276 ) on Tuesday September 04, 2001 @05:21PM (#2253020)
    What pretentious bullshit. Software is NOT art. It can be closely compared to bricklaying, or cabinet making, it is a CRAFT.

    Very perceptive...coding software is like crafting a cabinet. However, designing a cabinet is art...and so is designing software.

    Try expressing an emotion in C++. It cannot be done.

    jesus->loves(you); // Sarcasm, for the humor impaired

    Regardless, art doesn't just express emotion, it inspires emotion. And trust me, I've had (mostly other people's) C++ code inspire some pretty horrific emotions. ;-)

    Good design and coding, on the other hand, can truly be things of beauty, regardless of language.

    Please think before repeating these banal opinions that software is art. It just isn't. Deal with it, and if you want to be an artist, learn to paint.

    Spoken like someone who just doesn't really comprehend software design, or why one design might be more elegant than another. I suppose you don't think mathematics is beautiful either...

    186,282 mi/s...not just a good idea, its the law!

  • One can certainly succeed in meeting the user's initial basic requirements by writing a pile of spaghetti, but that doesn't make the writing of such sloppy code the preferred approach, at least in the general case.

    Unless you're writing one-off programs for your customers (and how many of those end up being used over and over again?), the long-term maintainability of your code must be kept in mind at all times.

    There's (usually) no guarantee that *you* are going to be the one maintaining the code in the future, at least many settings, and the people who will have to figure out how it works in order to maintain or enhance it will be extremely grateful if you lay your code out clearly.

    So will your users, as they will have to wait a shorter amount of time before that bug is fixed or the new feature added.
  • by Slide100 ( 150632 ) on Tuesday September 04, 2001 @05:24PM (#2253035)
    Software has to:
    1. Meet user requirements


    Unfortunately, in a great majority of cases, the user doesn't know what he/she needs.

    I can't count the number of times I have installed a system in a hospital (communications systems), made it run exactly to spec, and then have the staff say: "Why does it do that, we have absolutely no need for that! It should do this however".

    Generally, the specs are made by managers, not the people who actually use the device (program, etc). This causes the spec to be what management perceives to be the need, not the actual need.

    Granted, in an software situation, you are supposed to go through everything and find out what they need. How often does this happen? In most cases, a programmer is given a spec and told to write the software to it.
  • by Space_Nerd ( 255762 ) on Tuesday September 04, 2001 @05:24PM (#2253038)
    Well, in my experience beauty of code and how efficient that code is do not go hand in hand. The most efficient pieces of code i wrote were butt ugly and needed heavy explanations to my coworkers, but they got the job done in few lines and they took up little resources to do it.

    So what we want is no beautifull code, but really efficient one, and coding beautifully often goes against it.

    On the other hand, beautifull code is easier to maintain and to share, but its always best to have good code, not code that looks good.
  • Re:complexity (Score:5, Insightful)

    by oddjob ( 58114 ) on Tuesday September 04, 2001 @05:26PM (#2253052)
    Your argument rests on the assumption that something you don't know how to do is simple. The reason software quality is low is not because it is more complex than building a bridge.

    -- We've been building software for decades, but we've been building bridges for centuries.

    -- There are natural structures that resemble bridges that we have learned from. For most software, this is not the case.

    -- When a bridge fails, there is a good chance someone is going to die, so you'd better get it right. Software is rarely that critical, and when it is, it is usually better written.

    -- Also, when building a bridge, if you are sloppy about it, you're going to have a lot of dead workers. For coders, caffine overdose and sleep deprivation are seldom fatal.

    -- When building a bridge, it is difficult or impossible to correct mistakes after the fact. With software, just release a patch.

    -- When building a bridge, you have the contract before you start construction. With software, there is always the worry that a competitor will get a product out before you.

    -- If you build a bad bridge, you will get sued. Try and sue Microsoft.
  • Re:XP! (Score:3, Insightful)

    by Lumpish Scholar ( 17107 ) on Tuesday September 04, 2001 @05:29PM (#2253069) Homepage Journal
    The only reason that so much code is ugly is that most people do not know about and adopt XP.

    Extreme Programming (still abbreviated XP, despite Microsoft's attempt to dilute the abbreviation) may have a lot to offer many software development projects. But Kent Beck and Ward Cunningham and Ron Jeffries were capable of writing beautiful software before XP was codified, and programmers in XP projects are capable of writing ugly software.

    Refactoring backed by unit tests (two XP practices) can help reduce software entropy, and keep software from becoming ugly; granted. But XP extremism helps no one.
  • by Myopic ( 18616 ) on Tuesday September 04, 2001 @05:29PM (#2253074)
    I've seen this comment a lot in this discussion: "well, my software works, so it's good enough". You even say that you don't get paid to make pretty software; just usable software.

    I suppose that might be true, but I would venture that not everyone is in the same boat. I, for example, AM paid to write pretty code. My job is to come up with relatively simple perl scripts (modules) to solve various problems that Dartmouth [dartmouth.edu]'s website users have. (For example, I wrote a quota module to help people verify that files they want to write to disk will fit within their alloted disk quota.)

    I have NEVER turned in to my boss anything but well-documented, well-commented, readable code. I don't do this out of respect for my users; frankly, I know how to use the software and if they don't they can read my docs and try to figure it out. No, I do it for the other schmucks like me. At some point, my boss will probably tell his next lackey to add some little feature to one of my modules, as he's asked me to do with some older programmer's works. And it's DAMNED IMPOSSIBLE to wrap my head around code which is all mixed up. I comment for other programmers. People who might need to sink their hands into my code.

    Paying me now to write comments and format things well is worth it for the added speed with which the software will be maintained in the future. So for me, and I'm sure most of the code jockeys on Slashdot, the "real world" is one where software is written, THEN MAINTAINED. Beauty is part of maintanence.

  • by Anonymous Coward on Tuesday September 04, 2001 @05:36PM (#2253096)
    No, you've improved the analogy. Lets take your first example: The wiring. Your theory is that I, as a users, shouldn't care if little thought or planning was given to doing the job since i "don't see it".

    Of course, if when I go down to my fuse box I just see an unlabled rat's nest of wires I'm going to be mad at whoever did the (half-assed) job. Then let's say I decide to add a room. The new contractor comes to me and says, "Well, we can't figure out how the first guy wired everything so we're just going to add a second meter for the additional room and give it a completely independant system".
  • by greenrd ( 47933 ) on Tuesday September 04, 2001 @05:43PM (#2253135) Homepage
    But organisms, particularly humans, are far more resilient than any software yet created. Our brains don't usually "crash" completely, no matter what you throw at them. Metaphorically speaking, of course.

  • When it's done. (Score:3, Insightful)

    by verbatim ( 18390 ) on Tuesday September 04, 2001 @05:44PM (#2253137) Homepage
    It comes down to time and person-power. I think the biggest failing (from personal experience ;) )of most software/system design comes from either a lack of time or a lack of planning for time. The promise of "Technology" is here and now, but the bedrock is a sandy beach.

    The other important consideration is person power. It's not necessarily a lack of intelligent and capable people, but rather poor management of their time (either by themselves or from project managers). For example, working long hours in "crunch time" or being forced into the 9-5 cycle. Unfortunatly, my brain does not work on the 9-5. Sometimes I'll work for hours on end in an outpouring of inspiration while other times I'll be staring blankly at an equally blank screen.

    Another thing that corrupts software is the idea of "catch-all" systems. That is, does your web-browser _really_ need an IRC client? or, for that matter, an e-mail client? I think it would be helpful to break software down into individual, streamlined components that does one job - and does it really well, instead of doing a lot of jobs poorly.

    Just my 2 cents.

  • Good design is bad (Score:1, Insightful)

    by Anonymous Coward on Tuesday September 04, 2001 @05:46PM (#2253146)
    I know good design when I see it. I can produce good design. I practice good design in all my work.

    At the same time I must admit that good design is not good business. No, it does not take longer to come up and implement good design. The problem is most software engineers don't understand good design. They can't maintain it.

    Bad programmers can write code that other bad programmers understand and can maintain. They are the majority of the department so smart managers are wary of the one or two good designers they have.

    A tiny example:

    int strlen(const char *s)
    {
    int n;
    for (n = 0; *s++; n++) ;
    return n;
    }

    #define MAX_STRING_LEN 101 /* leave room for null character */

    int strlen(char s[MAX_STRING_LEN])
    {
    int i = 0,len;
    if (s[i] == 0) {
    return(0); /* don't forget empty string */
    }
    else {
    len = 0;
    while (s[i + 1] != 0) {
    len++;
    i++;
    if (i == MAX_STRING_LEN) {
    return(-1); /* error; need to revisit this */
    }
    }
    return(len + 1);
    }
    }

    The former implementation is more beautiful, but not something most software engineers could come up with. The uglier implementation is something they would immediately feel at home in. A good manager should discourage the better design "which only PhD's could understand and maintain."
  • by BWJones ( 18351 ) on Tuesday September 04, 2001 @05:46PM (#2253150) Homepage Journal
    Its messy if you do not know what you are doing. Just like coding or debugging.

    Biological systems are actually incredibly beautiful well structured, and in many cases optimized for their environment to a level unmatched in artificial systems. (I study vision and I see this sort of stuff all the time)

    At any rate, the analogy to biological systems sort of works and sort of does not. Biological systems are not planned, rather they evolve (valid arguments accepted for religion. However, in human experience, biological systems evolve as we do very little in the way of planning outcomes unless one is making transgenics or cross breeding. Even then we are often simply along for the ride). Software too evolves, but well designed software is thought out and planned in advance with lots of end user input, subject matter expert input, and testing of code and interface to meet the users needs. In my experience with others code and commercial products, most software goes right into the writing phase with very little forethought or planning. "We'll get to that later" is the phrase I have heard again and again. The programmers that stay and get rewarded are the ones that can plan, work with subject matter experts, and listen and implement ideas and suggestions successfully. The ones that will not work long for me are the Prima-donnas that try and force their code down everyone elses throat saying nothing else will work. The reality is that either they are too lazy, or not talented enough and are unwilling to work hard enough to become excellent programmers.

    I am seeing this more and more with the Microsoft way of writing code which is timeline driven rather than product driven. While being good enough for many, in reality it is third rate stuff without a commitment to excellence.
  • by Sebastopol ( 189276 ) on Tuesday September 04, 2001 @05:52PM (#2253183) Homepage
    DISCLAIMER: this is not a cheap shot at interns: it is a shot at managers failing to properly groom young hackers into veteran hackers with the humility to focus on the what's best for the project, rather than deft coding tricks.

    i've seen dozens of interns and new hires come in with 1 or 2 semesters of C, and write lots of code, sometimes important pieces of code. management seems to think that if you throw enough newbies at a problem, it's the same as one or two really good programmers. this is a huge management oversight. interns and new hires need good solid mentors and time to develop and hone their skills, and project management needs to enforce design rules. unfortunately, newbies are very reluctant to code to design rules, I know because I always wanted to do stuff my way as an intern (eight years later I'm writing design rules... irony). the result is like a meatgrinder on full speed: code spewing everywhere that all looks different, and is not being tested, regressed or reviewed.

    I've seen projects with strict design rules and rule checkers plus a technical guru/godfather for the project owner: results, fewer bugs and fewer people needed to support the code, and i'm talking about million line simulators.

    solution: mentoring by veterans with large program experience (the really mean veterans, they are the best people to surround yourself with); and a strict adherence to design rules and revision control; and regression/coverage testing!

  • Two problems (Score:3, Insightful)

    by The Pim ( 140414 ) on Tuesday September 04, 2001 @06:13PM (#2253276)
    There are two problems with this guy's approach:
    1. You can't learn to write good software by talking and reading about it in general terms. The best way to learn to write good software is the same as the best way to learn almost anything: practice, and get feedback from better programmers. Even though I think I understand where this guy's coming from, and I basically agree with him, I think his essay is basically pointless. I think the reason that so many of the posts here are critical is exactly that he is not specific enough to sway anyone who doesn't already look at the issue the way he does.

    2. To the extent that we do understand how to write beautiful software, we don't stand up for it. Although many posters make the obvious point that we are under pressure to get software done, this is not sufficient excuse for ignoring the values espoused in the essay, for two reasons: One, software that merely provides the required functionality may let the user get his job done, but typically requires him to learn the concepts used in the program and put up with its ideosynchracies, because the program doesn't work in terms of the concepts he already uses. This frustrates and alienates the user, and ultimately contributes to the low regard people have for computers. Look around you--almost every object pays some passable respect to usability and form. We shouldn't make (and sell) stuff that's ugly, cumbersome, confusing, and surprising, because it's dehumanizing.

      Two, software that is not conceptually clean is hard to extend. People often talk about maintainability, but it rarely gets priority during implementation. Why did Netscape's browser finally lose? Not because they didn't have good ideas for new features, but because it was internally such a mess that they couldn't improve it fast enough. This is not uncommon.

      So, even when we feel the very necessary pressure to get our code out the door, we need to push back in order to give more attention to beauty. We will benefit.

  • by KurdtX ( 207196 ) on Tuesday September 04, 2001 @06:21PM (#2253307)
    First off, I completely agree with the article, and am one of the biggest proponents of "beautiful software" I know, but...

    Not all software needs this much care Certainly if it's for you and your friends it can have all sorts of caveats, such as you can't have more than 3 windows open, and doesn't support adding and removing something at the same time, because the audience isn't big enough to justify the time. Sort of like how a lot of college kids build their own furniture out of 2x4s and cinder blocks. Which is sort of along the lines of:

    Some software is temporary Software with limited lifespan (especially those stopgap solutions) is often valued more if it is realeased sooner, so in my opinion it's acceptable for it to have rough edges. I think of it like those metal plates they put down to cover holes in the road while they lay pipes or whatever: they suck right now, but they'll be gone soon. Even for continuing projects a lot of features are faddish, in vogue while they are being designed, but by the time they get implemented, a new way is catching on. It's the pace of the industry that leads for so much corner-cutting.

    The complexity of large software projects is unprecedented I've often explained software to my (non-technical) friends as similar to building a car out of watch parts. And those are only for the smallish projects I've worked on. Software is virtually always a one-of-a-kind creation, so defects don't get "ironed out" over the production span. Actually, try taking 200 (or more) professionals from any discipline and see if they can work for a year on a project and see if they can produce something cohesive. Artists? They'd be too concerned about their individuality. Prototype car engineers? Ok, but what if they had to do everything by hand? That engine sure wouldn't be so smooth now would it?

    Point: Software creation is unique, in no other industry is there so little refinement of existing features, because there is such a high pace of invention. Only the Space Station seems (to me) to match software development in terms of scope, collaboration, and uniqueness; and it seems to have all the same problems as software development does.

    One last thing, these are excuses, but you should mostly listen to the article.
  • by Procrasti ( 459372 ) on Tuesday September 04, 2001 @06:29PM (#2253348) Journal
    Even Java works squarely against the goal of "efficient". Give me C++ any day.

    I've done projects in C, VB (im not proud), C++ (yep MFC et al, 5 years) and Java (1.5 years now), and I question the statement that java isn't efficient.

    I guess the gripe I have with this statement is your definition of efficiency. I won't argue that Java executes slower than an equivelent C++ program, after all it runs on a virtual machine that does have to do an amount of work to translate java byte code to native executable code, however, Moore's law applies here - machines and JIT (Just in Time) compilers will always get faster, as well as implementations of Swing and other graphics libraries.

    However, I also like to think of efficiency in terms of developer hours, support and maintainence. Java outshines C++ in its ability to clearly express your ideas in a way a machine can understand. It frees the programmer and maintainer of the details of memory management. Not that a developer doesn't have to understand memory management and the implications of holding references to objects, but that allocation and freeing of memory isn't a constant requirement. Every C++ program of sufficient complexity has to be tested and debugged for memory leaks - someone always forgets to add a destroy call somewhere.

    I won't even mention buffer overflow problems

    While I'm on the subject, and although I seem to be praising Java a lot here, there are always places for each language. I don't think Java would be a good choice of language to build a kernel in, for example. But a JVM based kernel? Well, a JVM couldn't be written in Java, could it? (think about that)

    And I wouldn't worry about Java being a proprietry language, as long as your java code executes in Kaffe and can be compiled with gcj (the gcc, java compiler, or something like that), then we will always have an open source program that will run accross many OSs and devices.

    To sum up, Java is generally a more elegent language than C++, this leads to code with quicker times to market, less bugs and less cost in support and maintenance - efficiency isn't everything, afterall, "premature optimisation is the root of all evil" -- Donald Knuth, and how much more premature can you get than in choosing the implementation language?
  • by Anonymous Coward on Tuesday September 04, 2001 @06:37PM (#2253398)
    That's about the most naive blanket statement I've ever read. "its always best to have good code, not code that looks good."

    Consider a project that lasts 5+ years. Over the life of the project, there will be dozens of developers added and cut from the payroll. Assume your "good code" gets executed once or twice a week and instead of taking 2sec it takes 1sec. You've saved 1sec (possibly 2sec) per week which adds up to 52secs (or 104secs) per year.

    Let's compare that to the human maintainer. Assume one person has to look at that code 1 time every 6 months and it takes them 30 minutes to understand it. That's 60 minutes that someone is getting paid to understand that code.

    If the person earns $80,000 US, that's about $4 (assuming 4 week vacation) that was spent on the human. It's actually less when you consider that a person's salary is not their labor rate. Over the life of the project (5 years) you've spent $83 on your "enhancement".

    Now, if the cost of up'ing the Mhz on your CPU is greater than $83 then it may make sense to implement the "enhancement". However, when you consider the price differential between a 900mhz processor vs a 933mhz processor (the argument being that a 933mhz processor could run the slow code and keep up with the 900mhz processor running the fast code) you won't find an $83 difference. It'll be more like $20.

    That being the case, humans are more expensive than computer CPUs these days. Maybe they weren't in the past, but they are today.

    Another argument for clean easily-readable and understandable code is that, if you take your argument, the entire system will become "enhanced" and no one will understand how it works. That will add on an additional overhead in the form of lack-of-enthusiasm for a project and will have financial implications.

    All in all, I've worked on XP projects where code formatting and understanding was important. And I've worked on government contracts where people hack'ed their way through to save a couple of cycles. Maintainability speaks volumes... And I'd go with readability and understandability in a heartbeat...

  • Re:complexity (Score:3, Insightful)

    by Keeper ( 56691 ) on Tuesday September 04, 2001 @06:50PM (#2253447)
    There is a lot of complicated math involved in civil engineering; I believe the knowledge required is much more than the knowledge required to program a computer.

    One of my best friends in college just finished their masters this weekend. She most definately did not slack off for the last 6 years; I can't count the number of times she pulled all nighters to get things done.

    The difference between engineering a bridge and writing software is that all of the major problems with building bridges have been solved. There is a lot of math and a complicated series of steps and tons of engineering work involved, but the problems have been solved. We already know how to build bridges. We may not know the particulars on how to build a bridge that spans 2000 feet and can hold 500 tons, but the basic theory on how to do this is known.

    Additionally, the application for civil engineering projects are very well defined. They have a small task that they need to perform.

    I think that the most interesting work being done in civil engineering these days is materials research.

    Software on the other hand doesn't have all of the problems already solved. We've come a long way in the last decade or two, but we've come far from solving all problems. I think it's safe to say we've solved all of the simple, basic problems, but the more complicated problems still exist.

    The other problem with software is the scope. The scope of most software packages today is HUGE.
    It involves problems that havn't been solved a 100 times already. And they are non-trivial problems. Sometimes the problems are actually hard to understand -- how do you approach a compression or encryption problem for example.

    Another problem with software that makes it hard to compare with civil engineering is that it only takes one mistake to bring the whole thing crashing down; on a bridge, odds are if a bolt is misplaced the bridge will not fall -- there is built in redundancy; this is not a feature possible to have present in software (not unless you write the software 3-5 times, and have an agreement between routines about the result of a function call).

    There are tons of differences between traditional engineering and software engineering that makes comparing the two fields difficult if not impossible.

  • by jafac ( 1449 ) on Tuesday September 04, 2001 @07:04PM (#2253514) Homepage
    basically, you're talking about the problem being that the product is being designed by people other than the engineer.

    Marketroids designing projects and setting schedules will get you an end product that does not appear to be well engineered. Because the engineer didn't design it. The Marketroids did.

    You want software that works? Put the engineers back in charge.
    But then the company that does that will be out of business by the next development cycle. Because their product won't look nice on the comparison matrix.

    Ease of use and word-of-mouth doesn't cut it anymore in this industry. You need the trade rags sucking up. And that takes marketroids.
  • Excellent book (Score:4, Insightful)

    by Phrogz ( 43803 ) <!@phrogz.net> on Tuesday September 04, 2001 @07:11PM (#2253537) Homepage

    For a particularly good book describing the problem and situation (fabulous for understanding the flaws in most businesses software design methodology, and more importantly for convincing managers that this is the case) then you should read The Inmates are Running the Asylum [amazon.com] by Alan Cooper, the 'Father of Visual Basic' and also author of About Face: The Essentials of User Interface Design [amazon.com].

    It's light on concrete solutions (although the foreward addresses why that is the case) but still a useful primer to read even if you want to solve the problem, since the first step to solving a problem is properly understanding it. It's so fabulously refreshing to see in print a rather respected person describing the problem as I know it to be true, and especially providing big-business, big-name, concrete examples to point to and say, "SEE! IT REALLY DOESN'T WORK TO SET ARBITRARY DEADLINES AND TO START CODING WITHOUT PROPER SPECS!".

    This issue is just a little bit important to me :)

  • by Jerf ( 17166 ) on Tuesday September 04, 2001 @07:15PM (#2253559) Journal
    Ever designed a bridge? Do you know how long it takes? Did you know you only get one chance to get it right during the implementation stage?

    While your reaction is understandable, and it's easy to overstate software complexity, it is not entirely untenable to maintain that software is an unusually complicated beast, by most any useful metric.

    "Useful metric" is where the standard falls down. What metric can we use that makes sense? Can one person understand the design of a bridge? I daresay yes. Can one person understand all of Windows to the same level? I daresay no. Is that a fair comparision? What is a fair comparision?

    We lack a metric of complexity. So I'll submit this: By the rule of mediocrity, "on average, everybody is equally stupid", we must say that software is more complex then bridge-building, because we know how to build good bridges. It's been a while since I've heard of a bridge honest-to-goodness failing from something other then lack of designed maintenence. Software, on the other hand, is still problematic and we've been trying to figure out how to build it for years.

    Self-flaggelating (or, if you are not a programmer, flaggelating others whom you don't really understand) is not really useful. Attributing bad software to extra stupidity on the part of the software authors is quite disingenuous. Odds are, if a lot of very smart people have been working on the problem and haven't come up with a solution yet that seems to work, it's because it's a hard problem, not because the smart people are extra stupid.

    (It's also worth pointing out that the few software team structures that do seem to produce useful, reliable, etc. code also require truly massive expenditures on design, testing, testing, and more testing. Without proof, I'm willing to claim that the amount of money spent developing the software for, say, the Space Shuttle in this manner grossly exceeds the design+labor of any bridge you care to name. (Discount materials for the bridge, there's no clear equivalent in software.) And that's just Space Shuttle software... that doesn't help you email Granny.)

  • by mpcooke3 ( 306161 ) on Tuesday September 04, 2001 @08:15PM (#2253756) Homepage
    My personal experience is that extreme programming (XP) produces code that is exceptionally good quality at a low level but not so great at an overall architectural level.

    The reason for this I believe is the heavy use of Unit Testing. By testing first you have normally thought of a very elegant/simple design by the time you write the real code. It is also easy and safe to improve the code because you can check it passes the tests. But the tests also mean there is a great reluctance to change the overall architecture of a project because you will break hundreds of tests that will need to be moved, changed or rewritten.

    Another thing that helps with code quality in XP is the fact that you write it with a partner and within a week at least 5 other people will probably have criticised it :)
  • Re:complexity (Score:5, Insightful)

    by StevenMaurer ( 115071 ) on Tuesday September 04, 2001 @08:27PM (#2253780) Homepage

    That's an easy one to answer. Software companies don't back their products because their customers don't expect them to. Instead they expect low prices.

    Bill Gates is a billionare because he was one of the first people to realize that given a choice between a $200 program that works flawlessly and a $99 program that fails 5% of the time, most people (and businesses) will choose the cheaper product (while moaning how bad software is).

    Note that this isn't the case in all software markets. Banking and T.V. are both industries which I've worked in, in which customers actually demand quality. If it's crap, they won't buy it no matter how cheap it is.

    Funny enough, Microsoft is not in either business - and not for lack of trying.

  • Re:complexity (Score:3, Insightful)

    by sterno ( 16320 ) on Tuesday September 04, 2001 @08:34PM (#2253799) Homepage

    When building a bridge, you have the contract before you start construction. With software, there is always the worry that a competitor will get a product out before you.
    BINGO! I cannot recall at any point in my 4 year career as a software developer that any given project had concrete and immutable goals before beginning of development. On the best projects we'd have good documentation of requirements, etc, but EVERY time those requirements would change.

    To compare software design to bridge building or most feats of industrial or civil engineering are ludicrous. To put it in perspective imagine this scenario:

    The city planning commitee has contracted to have a bridge built. Original bridge specifications called for four lanes of traffic. The city planning commitee now has decided it must have 8 lanes and the bridge is already halfway done. Do you think the bridge builders are going to stop construction and re-engineer on the fly? If they did, you can bet that bridge would collapse. No, they won't do that, they'll build the bridge, collect their check and go home.

    That sort of scenarios ALWAYS happens in software. Why? Because everybody knows they can get away with bugs, that patches can be released, that ultimately getting it right the first time isn't 100% critical. So they don't worry about it, and why should they? It would be inordinately expensive and arduous to design all software to the tolerances associated with civil engineering, and it would provide questionable benefit in the end.

    The big problem with software engineering principles is that we keep trying to find physical world metaphors for the way software should be designed and they all fail. Why? Because the physical is, for the most part, immutable. So how can you apply those same design methodologies to something that is infinitely mutable? The simple answer is, you cannot. Sure, some aspects may be adaptable, but ultimately accepting that building software is completely unlike building a bridge will make life much much easier.

  • by Fortmain ( 469266 ) on Tuesday September 04, 2001 @11:10PM (#2254219) Homepage
    Beauty isn't really the issue here, it's maintainability. The current project I'm on, I 'inherited' someone elses butt-ugly code. It did the job fine, but I spent the first six months reading, re-reading, and testing, just so I could understand what the thing was doing. All told, I spent over a year just getting comfortable with the program. Meanwhile, I'm also supposed to be updating this thing for a new release every six months! Every chance I got I did 'code clean-up', fixing things that worked, but were difficult to understand the logic of, or just plain stupid (take a long, often-used routine, and make it in-line everywhere rather than use a function!?).

    Finally, after two and a half years, I get the chance to re-write the whole thing into Java. (I know, it wouldn't be my first choice, but ANYTHING beats Powerbuilder!)

    The point is, unless you are writing 'throw-away- code, your program may exist for many years, and have many people maintaining it. We need to do ourselves a favor and make sure that we can understand what we all write. Memory is cheap, so there is no good reason not to write good, clean, easy to follow code.

    And don't give me the argument that "we're up against deadline". I've been playng this game for twenty years, and I know that every minute I spend in the design phase is like an hour saved in the coding phase. Design the thing first! Make sure you know how it is going to break down into the various modules you will use. If you design it right, the code will flow, and you will make your deadline easily.

    I know, all you young hotshots out there won't listen to an old fart like me, but eventually you will either learn the hard way that I am right, or you will burn yourselves out and never want to code again. Meanwhile, _I_ get stuck trying to maintain the crap _you_ wrote!

  • by danox ( 232017 ) on Tuesday September 04, 2001 @11:36PM (#2254262) Homepage Journal

    I agree, and actually I would go so far as to say that bridges are not that different to software

    Having studdied civil engineering before I moved into computer science, I found that the basic rules are the same, you design the bridge or whatever to the required specs, cutting costs wherever possoible. The only real difference is that most customers tollerate software bugs, whereas your average city full of people will not tolerate a bridge that falls down in the normal corse of business

    Civil engineers put allot of effort into their designs becasue they have to, there are laws in place to make them do so. If these laws were not in place we would see many bridges falling down. These laws are just another requirement. If there were laws stating that software must contain less than so many bugs, then that would be another requirement and you would find that more effort was put into the design of the software to ensure this requirement was met.

    So really, the comparison does not really prove anything except that software companies don't need to design their products as well as civil engineers do. Its not usualy a requirement.

  • by Peyna ( 14792 ) on Wednesday September 05, 2001 @12:27AM (#2254373) Homepage
    Beauty and Art are two different things.

    (i.e.) I think a Porsche would be beautiful in my garage, but that doesn't mean a Porsche is a work of art.

    I suppose if you were going to compare coding with art (literature), coding would be non-fiction. Some of it is horribly written, but it's got all the facts right. Some of it is written wrong and doesn't make any sense. While the truly good works of non-fiction, even though they are only telling you facts, are beautiful, fill your mind and heart with thoughts and feelings, and are 100% accurate at the same time.

    In that sense, yes it is art, and like with a non-fiction book, you can copyright the finished product, but you can't copyright the facts that make it up.

  • by Anonymous Coward on Wednesday September 05, 2001 @12:32AM (#2254395)
    Software developers are not *ists. Neither are painters, musician, dancers yada yada yada. * is a meme that allows people to feel better about themselves ( particulary in relation to others ) by inclusion in the group that are *ists or KNOW what * is. The primary effect is to EXCLUDE all those other unenlightened people who are in the dark *istically.

    I play piano/keyboards, compose music and write software. I am NOT an *ist. I am amazed at all the confusion surrounding this evil meme. If you remove the word from your vocabulary and remove the concept the concept from your thoughts, the problem goes away. You'll see things in a new light. Carriers of this meme act under compulsion to be included among those who know what * is.

    Free yourself. * doesn't exist.
  • by harvardian ( 140312 ) on Wednesday September 05, 2001 @01:16AM (#2254501)
    Can I amend that to:

    1. Meet user requirements quickly

    When you build a bridge you have plenty of time to design and implement it. And that bridge will last decades, if not centuries.

    Software, however, isn't meant to last. It's meant to take advantage of cutting edge technology RIGHT NOW. You don't write a program to last for 100 years. You write it to last a maximum of 5 (longer for sparse exceptions). That's why software is often so ugly.

    Maybe after 30 years we'll have an OOPL that will eventually take the cake, and some sort of system where we don't change APIs every month. Then maybe people will be able to write code for the long term, knowing it won't be obsolete in short order.

  • by BeforeCoffee ( 519489 ) on Wednesday September 05, 2001 @03:34AM (#2254667)
    Programming software is nicely compared to real world construction except that ...

    Building a house, a bridge, construction in general, that's all physical stuff. Humans are created to be good at physical stuff. Nature has given those industries an advantage. Everything in software development is by-proxy, it's all metaphor - pure language: more like poetry than mixing concrete. Humans are very good at metaphors too, but the pure metaphors found in software development often tax our limited processing powers in ways unrelatable in physical construction.

    Pile on top of that that, as was mentioned before, there are standards to these construction craft that have been refined over thousands of years. Software development has what, 50 years of science behind it?

    Finally, in physical construction, there are powerful tools (steam shovels, cranes, concrete, steel) that come "canned" or "out-of-the-box" to which there are no real parallels in software development. There is off the shelf software that looks good, but it never "plugs n' plays" like we really want it to. There are development tools, (debuggers, profilers, editors), but they are primitive by physical process standards.

    I suppose I could come up with a ludicrous example of software development, likening it to some sort of construction project where the site is in the wilderness, and I need to pave my own road to get my trucks to the site, and I have to smelt my own steel from my own mines once I get there, and then I have to make homemade concrete, and on and on ... but that would never be an relevant example: real software development is a convoluted and fluid transmission of ideas rather than a construction of anything - even in the ideal CASE tool driven, XP driven, UML driven, highly "engineered" environment. Again, it's a lot more like writing or speaking than like construction.

    This is why I believe that component development is on so many people's minds, why Enterprise Java Beans are looking SO attractive. Biz people and developers want powerful "canned" tools that they can "assemble" to form complete programs. They want relatability too, they want software processes to be easily relatable to physical or business processes.

    It's going to take more time; the tools and science will need to progress more. As CPU and memory become more bountiful, we'll waste more on frivolities that make the computer itself more relatable. This will, in time, help to reduce programming to more natural forms of human communication and interaction. The computer will eventually be able to learn about a problem space and "develop" solutions with a programmer's help.

    My hope is that the democracy and ubiquity of natural language programming will elevate the potential quality of code produced to that of fine literature or other great works.

    -- BeforeCoffee
  • by Ukab the Great ( 87152 ) on Wednesday September 05, 2001 @04:57AM (#2254775)
    But you have to know what to look for. I've often found a badly designed user interface to be a real tip off that other parts of the software are crap. I'm not talking about pretty pictures and cute icons (which, unfortunately, is what a lot of people in the free software community think constitutes usability), I'm talking about whether widgets are laid out in an unambigous manner and whether operation of the interface is efficient and cognitively sound. If a company designs one part of the system in a very half-assed manner, they'll most likely do the same with the other part, too.
  • by KGBear ( 71109 ) on Wednesday September 05, 2001 @08:28AM (#2254977) Homepage
    software is just as good as people are willing to

    pay for. I'm building a house right now and the

    contractors showed me the bottomline: cheap, fast

    or durable: pick any two. People don't want good

    or safe code. They want code to be cheap, sexy

    looking and more importantly, they want it now. Or

    yesterday. As businesses and individuals, we

    should stop behaving like whores and selling

    whatever the customer will pay for and be more

    like my construction contractors.
  • Market maturity (Score:2, Insightful)

    by pkesel ( 246048 ) <(ten.retrahc) (ta) (lesekp)> on Wednesday September 05, 2001 @08:39AM (#2255009) Journal
    The software market, and in fact the entire computer industry, is not mature enough yet to offer a high level of sophistication and uniformity. It's where auto manufacturing was in the early part of last century. There are a few mass marketers producing vanilla products for those who are dying to spend for it. They have the upper hand becasue people are going to buy whatever they can find. If you want a high scale product you're going to have to pay someone to make it for you. Otherwise you get what they have to offer, and it's good enough because it's the only thing you have.

    Computers have only recently become a mass market item. It's still a bit of a luxury item. When cars were at this point you couldn't count on their reliability or safety. It took decades of refinement, regulation, and standardization before they became the daily commuter that we rely on today. And still after a century you can't take even a bucket seat from one and put it into another, even from the same manufacturer, without adaptation.

    The sad fact is, you're probably born at that time when you'll never see a mature computing market. For the most part we're still working from the direct decendents of the first IBM PC. Still working from the first UI to make computers usable for about everyone. We're still defining what a computer is!

UNIX was not designed to stop you from doing stupid things, because that would also stop you from doing clever things. -- Doug Gwyn

Working...