Slashdot Mirror


User: David+Gould

David+Gould's activity in the archive.

Stories
0
Comments
711
First seen
Last seen
Profile
(view on slashdot.org)

Comments · 711

  1. Re:Many own, few read on Knuth's Art of Computer Programming Vol. 4 · · Score: 1


    tmp = a[j]; /* swap a[j] and a[j+1] */
    a[j] = a[j+1];
    a[j+1] = tmp;

    Meh. A real programmer would have written:

    a[j] ^= a[j+1];
    a[j+1] ^= a[j];
    a[j] ^= a[j+1];


    But seriously, the idea of using a machine-level language isn't to get caught up in "bit-twiddling" at the expense of high-level understanding. It's to be sure to show the steps more explicitly (and thus more clearly). Using "a language so simple even a computer can understand it" ensures that it's clear exactly what every step is actually doing, which, especially for new students, helps with the complexity-analysis part. Of course you also explain the "big picture" of the algorithm at the natural language level, and probably also at the pseudo-code level.

    To answer your question, which version in your example better explains how BubbleSort works? The English version, of course. (Well, it would if it were correct, but others have already picked those nits.) But which one makes it easier for a first-year student to see that the runtime is n^2/2 compare-and-maybe-swap operations (and from there to understand what it means to say that it's O(n^2))? Methinks it's the C version.

  2. Re:Wasn't Mozilla on Mozilla Roadmap Update · · Score: 1


    I've never understood why that was ever even suggested. Then again, I still don't see what's supposed to be so much better about FireFox, compared to Mozilla, in the first place[*1]. I haven't found it to be significantly faster or more stable. Of course, I haven't found Mozilla (since somewhere in the 1.2-1.4 era) to be particularly slow or unstable, except when I start really stressing it, like by having half a dozen windows open, each with 30+ tabs, and keeping it like that for months at a time.

    But by the time you've got 200+ web pages open at once, many with animated GIFs (or, God forbid, Flash) running, you're pushing the limits of the hardware, and can't reasonably blame the software. It starts to degrade more-or-less gracefully, but certainly better than any other desktop software I'm familiar with.

    I've never pushed FireFox that far, but even at more normal levels, its memory and CPU footprints really don't seem much better than Mozilla's (which, admittedly, are a lot higher than I'd like to see).

    For my personal needs, I don't like FireFox's stripped-down interface: it feels more like a "toy", to Mozilla's "serious 'power-user' browser". I know not everyone wants a "power-browser" but that's exactly why both should continue to exist!

  3. Re:Wasn't Mozilla on Mozilla Roadmap Update · · Score: 1


    We all know Mozilla has an big amount of features, many of which we never use, so the idea is that there would be some sort of vendor or someone making a distro who would customize it properly for its users/customers.

    Nicely said. But not only that: what you described is exactly what FireFox should be!

    I haven't kept up with the development history, but it seems that FireFox became much more of a fork than it should have. I should think most of the UI changes (whether or not you call them "improvements" -- I generally don't) could have been done as exactly that kind of customization, and the things that couldn't -- whatever real "under-the-hood" improvements there've been -- could have been done on the main tree (a branch if necessary, but with high priority on merging them back in as quickly as possible).

    So then, instead of a whole separate codebase, the FireFox build would consist of little more than a separate "gmake" target, omitting certain components and substituting different high-level stuff (xul, chrome, etc.) I don't know if that's how it is or not, but I get the impression it's not -- can anyone confirm or deny?

  4. Re:And here is the joke... on Backing Up is Hard to Do? · · Score: 1


    Yes, thank you. Because of course, nobody else had any idea what they were talking about.

  5. Freudian typo on Disney Plans Tron Remake · · Score: 1

    I liked tron, but I can't see how they'll retain the "feel" of the original. I won't say it's impossible, but it just seems like they're setting people up for disappointment.

    Perhaps that's why TFA says: (emphasis added)
    Sternthal told the trade paper that the new conceit is that the computer programmer gets trapped in a cyberworld, so that the film can utilize the Internet.
    Sigh. I swear, sometimes the jokes just make themselves.

    (By the way, who else is impressed by this demonstration of groundbreaking originality? I mean, like, wow -- who could have ever imagined that a modern-day remake of the TRON story might involve The Internet?! How do they come up with this stuff?)
  6. Re:come together on Microsoft's Technical Glitches at CES Explained · · Score: 1


    in which Bill Gates refers to people who disagree with him on IP issues as "communists" repeatedly.

    Don't know the origin of this, but I think I got it from a Slashdot sig:

    Linux is as much about "Communism" as is the phrase "Of the People, By the People, and For the People".

  7. Re:Thin Ice on Countries Plan Land Rush in Warming Arctic · · Score: 4, Funny

    Actually, the apparent contradiction in reputation for temperament between Scandinavians and Vikings can be explained even more easily than that:

    A Viking is a Scandinavian without his coffee.

  8. Re:Define cost less on Are Nanotube Monitors In Your Future? · · Score: 3, Insightful


    just that all we ever hear about are all these amazing magical technologies that will blow the existing techs away.

    You mean like plasma screens? You know, it wasn't that many years ago that we were discussing, right here on Slahsdot[*1], an article that sounded just like this one, but was introducing a hot new display technology called <fingerquote style="Dr. Evil">"plasma"</fingerquote> that was going to enable flat displays to be made bigger/better/cheaper than was possible with LCDs.

    Then too, the article was overly enthusiastic; then too, some of us got prematurely excited about it; then too, others soberly advised waiting for actual products, etc. In short, it was exactly the same as this. And yet, the technology really did arrive eventually.

    You're right that it's stupid to get all excited about an R&D concept demo (or even an actual prototype) as if it were an actual product (and by the way, it's called vaporware, not FUD -- similar concepts but an important distinction). But it would be just as dumb to completely scoff off all new-tech press releases. We should take an article like this for what it is, no more, no less: a preview of one of the (several, competing) possibilities for what might become the next generation of display technology.

    We know there's going to be a next generation, and between SED, FED, OLED, Thin-CRT, and WIMF, there's an exciting amount of potential for displays to get dramatically bigger, better, and cheaper sometime in the not-too-distant future. I for one am content to leave it at that, and interested to keep an eye on developments on all those avenues.

    --
    [1] At least, some of us, who were around back then. I think I'm supposed to make a comment about /. UIDs at this point, but I can't stand those people who get all cocky about their "old-timer" status.

  9. Re:Early warning on The Coming Atlantic Mega-Tsunami · · Score: 1


    It is thought that the tsunami will be caused by a volcanic eruption.

    Not necessarily, if this is the same thing I remember hearing about a while ago. Iirc (a big 'if', admittedly), this is indeed a volcanic island, but the dangerous part isn't actually an eruption. It's just that there's a huge piece of the island that's poised to snap off and drop into the ocean and make a big (big) splash. It wouldn't necessarily be triggered by an eruption; it could just snap and drop at any time.

  10. Re:Everyone has his price on Microsoft Critic Received $9.75m After Settlement · · Score: 1

    $9.75 million? Hell, I'd stop criticizing Microsoft for a tenth of that! I mean I'd really, literally, never say or write another unkind word about them. Come on -- how many people here can honestly say otherwise?

  11. Re:Not really on Author of Linux Patent Study Contradicts Ballmer · · Score: 1


    As Bart Simpson had to learn the hard way (episode AABF05) :

    "The President did it" is not an excuse
    "The President did it" is not an excuse
    "The President did it" is not an excuse
    "The President did it" is not an excuse
    "The President did it" is not an excuse
    "The President did it" is not an excuse
    "The President did it" is not an excuse
    "The President did it" is not an excuse
    "The President did it" is not an excuse
    "The President did it" is not an excuse

  12. Re:Rank them by importance on What's Next For Mozilla? · · Score: 1


    I belive it'd be best understood as a sort of corollary to Zawinsky's Law of Software Envelopment. JWZ said "Every program attempts to expand until it can read mail". Though email is specified as the featured feature, it's explained as just a special case of the broader tendency of software packages "to evolve into toolkits and application platforms". With desktop search apparently being the "hot new killer app du jour", we can easily see how it makes sense to substitute "perform desktop searches" for "read mail" in the original observation.

  13. Re:Perl goodness on Perl 6 Grammars and Regular Expressions · · Score: 0, Flamebait


    The regular-expression syntax is far from being the only reason for Perl's reputation as a write-only language.

    As reported, here, there's also the matter of the ridiculously large and cryptic collection of global and internal variables ($@_$%&|`). And then you've got optional punctuation (including such essentials as quotes for string literals and parentheses for function calls) and all the freakishly bizarre syntactic constructs for referencing and dereferencing objects (and people think "*" and "&" in C are confusing -- sheesh!).

    I could go on for hours listing the things I found to hate about Perl when I had to use it, but now I've got some PHP code to get back to.

  14. Sigh... on Titan's Smooth Surface Baffles Scientists · · Score: 1, Interesting


    I see there are at least six people who still think these "geeks never get laid" jokes are funny. (One to post it, one to post a "mod parent up", and four to mod it up.) One continues to wonder how long it'll take until they realize that the joke's actually on them. Hint: you six are pretty much the only ones, 'mkay?

    True, most of us have a tougher time than other guys, but for many (most?) of us, it does happen at least once in a while, and plenty of us are getting it all the time. So there.

    It's time to try being funny about something else.

  15. Re:This is /. right??? on X Prize Launch At Mojave Spaceport [updated: success!] · · Score: 4, Insightful


    ahh, let the religious types have their comfort. Doesn't hurt anything until it starts to infringe on our rights.

    Change the second sentence to past tense, and I'd agree.

  16. Re:Spoken like someone who has never done it on Zero Gravity Flights for the Rest of Us · · Score: 1


    IHNTA. IJLS "nuclear wedgie". Thank you.

  17. Re:Best bonus question EVER on General Solution for Polynomial Equations? · · Score: 1


    One point of extra-credit to protonman.

  18. Best bonus question EVER on General Solution for Polynomial Equations? · · Score: 1

    My favorite bonus exam question (from a CS Theory midterm for the portion of the semester that covered the Fast Fourier Transform):

    (Extra credit -- 1 pt.) Simplify:

    (x - a) (x - b) (x - c) ... (x - z)
  19. Re:Mr. Lizard! on Muppets Named Top Scientists · · Score: 1


    *ahem* I believe it was "Weeeee're gonna need another 'Timmy'!"

  20. Re:More than Just P=NP on The End of Encryption? · · Score: 1


    (-principe du tiers exclu in french, i don't know in english)

    "Principle of the excluded middle" is what we called it in school -- basically an exact word-for-word translation between the English and the French, in this case.

  21. Re:proof of P=NP without supplying an algorithm on The End of Encryption? · · Score: 1


    I think I agree, though I'm having some trouble imagining what form such an "existence proof" could take, other than providing a P algorithm for some particular NP-Complete problem. Or at least, providing enough of an outline of such an algorithm that, even if the proof can stand with a few details of the actual algorithm left as an exercise for the reader, filling in the gaps wouldn't be too much harder.

    I understand you're probably talking about something completely different, namely, a completely abstract existence proof that would work without even hinting at any actual algorithm. But like I said, I'm having trouble imagining how that would go.

    I haven't studied that much algorithm theory, but all the NP-Completeness proofs I've seen have consisted of providing an actual algorithm for reducing problem X to some already-known-to-be-NP-Complete problem Y (plus verifying the succinct certificate property of X's solution, which is usually relatively trivial). Of course I realize a P=NP proof would be a very different sort of thing, but I've always imagined it taking a similar form.

  22. Re:google..... on Internet Meltdown Predicted for Tomorrow · · Score: 1


    The way they teach it in elementary school, "average" is the sum of a bunch of numbers, divided by the number of numbers. I.e., It's exactly the same as what we more-mathematically-advanced folk call the "arithmetic mean".

    The fancier term "measure of central tendency" refers collectively to the kind of thing that "mean", "median", and "mode" all are. It's true, I guess, that when speaking very loosely, you might use "average" to mean "measure of central tendency", but usually, I think, people who know enough math to be aware of the difference would know which specific term they mean and use the correct one, and if "average" is used at all, it's in the elementary-school sense, i.e., synonymous with "mean", when you really mean "mean".

    Even if you do use "average" to refer collectively to all of the specific terms, using it to specifically but ambiguously mean any particular method of averaging other than "mean" is considered harmful. And confusing the median with the mean is especially bad, because the technical difference between them is often so very important.

  23. Re:Stephenson's sex scenes on Locus Interviews Neal Stephenson · · Score: 1


    My "vantage point" during this section of narrative was basically above the center console

    You mean, you weren't reading in "first-person shooter" mode, from Randy's point of view? I'm pretty sure the reader is supposed to be identifying with Randy there (or is it just us male geeks?).

    Let me see -- so you were looking at them from the side, so you saw them in profile, with Randy on the right and Amy on the left? Oh, I think I get it -- you were also a bit forward, looking back at them, so you could see past her to the door? Okay, the door would be on the left edge of the screen from that point of view in a normal (i.e., American) vehicle. I can see how that could work.

    Not sure I buy it, though. Like I said, I'm pretty sure the scene was supposed to be seen from Randy's point of view. (I know I was in first-person mode, seeing it through his eyes, which is also why it was so disorienting to have the whole scene suddenly twisted around.) And if I were filming it, I think I'd put a camera on the driver's side back seat, looking diagonally forward over Randy's shoulder, so it'd see part of his face and see Amy almost head-on. That way, "stage left" equals "Randy's left" equals "vehicle left". And if that's where the passenger-side door is, that makes is a non-USian vehicle.

    In short, I still think it was one of Stephenson's deliberate head-games. There's no denying he likes messing with his readers that way. Not that I'm complaining -- it's actually one of the things I love most about his writing. Ok, now I need an official answer from him. If Slashdot ever does an interview with him, I'll repost this.

    Incidentally, as I don't have the book with me, what country was this in, and have you verified that the seating is the opposite of the USA?

    They were in the Philippines at this point (having snuck back there to look for the big gold cache). I don't know how people drive in the Philippines, but this part was set in a back-country area, and the origin of the vehicle was not known -- I remember getting a vague impression that it might have been brought in directly from somewhere else anyway, not bought in that country.

  24. Re:google..... on Internet Meltdown Predicted for Tomorrow · · Score: 2, Insightful


    Don't make me come over there and explain (again) the difference between "average" and "median".

  25. Stephenson's sex scenes on Locus Interviews Neal Stephenson · · Score: 1


    A lot of Stephenson's sex scenes aren't really bad. They're just... weird. For one thing, they're rarely anything that you'd call "erotic" -- if anything, he seems to try his best to avoid making it erotic. And yet, he'll succeed at making it very clear how intensely erotic it is for the characters; there's plenty of excitement for them, just none for you. He also has a way of emphasizing some of the less pornogenic but more realistic aspects of sex, like premature ejaculation, prostate issues, and the post-coital need to pee ("...to flush the remaining semen out of your urethra, lest it dry in there...").

    But you know the single most disconcerting thing he's ever done? I've been needing to get this off my chest since the first time I read Cryptonomicon, (circa 1999) and whenever I think about it, I still get all twitchy. It's the Randy/Amy scene near the end: Randy was sleeping in the passenger seat of the SUV, when (to make a short story even shorter) Amy climbed in, had her way with him, and "exited stage left."

    Waitasec... 'Left'? I thought he was in the passeng-- AAAAARRGHHHH!!!! IT'S AN SUV BUILT FOR A COUNTRY WHERE THEY DRIVE ON THE WRONG SIDE OF THE ROAD! THE DRIVER'S SEAT IS ON THE RIGHT AND THE PASSENGER SEAT IS ON THE LEFT! MY ENTIRE MENTAL IMAGE OF THE SCENE HAS BEEN FLIPPED BACKWARDS ALL ALONG!

    Before you tell me to lay off the coffee (just had my second double latte for the day, thanks), think about it for a minute: The way the story is written (not just that scene, but the whole narrative flow), it had me pretty deeply "in the zone", with a very vivid mental screenplay following along. Then comes the sex scene, making it even more vivid. Then at the end of the scene, when I'm visualizing the inside of the vehicle (something that one can visualize very clearly because it's such a small and familiar environment), I suddenly realize that I've had everything the wrong way around. The door that she came through is on his left; the driver's console is on his right; he's been sleeping with his body slumped the other way; the kink in his back, the crick in his neck, and the cold spot on his temple from leaning against the window are on the opposite sides, etc., etc.

    Believe me, it was a physically painful sensation, like my brain was trying to turn sideways in my skull. I had to go back and try to mentally re-choreograph the scene, but I just couldn't make it feel right.

    I'm almost certain Stephenson did this deliberately -- he seems to love playing that sort of mind-games on his readers and burying little Easter eggs all over the place. I wonder what percentage of readers noticed it. (Anyone?)