March, 2010

  • The Old New Thing

    Germans are falling for the same trap as the Japanese: Importing words from English and changing the meaning, but the Germans do it even though the words didn't need to be imported at all

    • 73 Comments

    Languages borrow from each other all the time. English has historically been a happy perpetrator of word-theft, but in recent decades, it has been serving as the source for a lot of theft, too. What I find particularly interesting, though, is when a word is borrowed and given a meaning in its new language different from its meaning in the source language.

    Japanese is famous for this, For example, they take the English phrase white shirt and import it as waishatsu, which means not white shirt but dress shirt.

    In Swedish, the phenomenon of importing English into Swedish is known as svengelska, a blend of svenska and engelska. The Swedes use the faux-English term service-mind to mean dedication to customer service. I find this interesting because they just took some English words and combined them in a way not used in English at all. And as you can see from the citation, it seems that there are some who are under the mistaken impression that we use the word in English, too.

    One thing that disturbs me is when a word is imported into a language even though there is already a perfectly good word for the concept. Many years ago, my aunt (who at the time was a Japanese teacher) went to Japan and sat down in a restaurant. She looked over the menu looking for the beverages and couldn't find it. She asked the waiter where the beverage section was, and the waiter directed her to the section titled dorinku. The Japanese have imported the word dorinku from the English word drink, displacing the traditional Japanese word (which I believe is nomimono, but I could be wrong). My aunt was looking for the traditional Japanese word and couldn't find it.

    The award, however, for using faux English terms, goes to the Germans and Denglisch, the term for the blending of Deutsch and Englisch. Unsatisfied with the perfectly good German word Rucksack, which means backpack, some marketing geniuses decided to adopted the English word body bag instead. This is wrong on so many levels. First of all, it's the phenomenon of replacing a perfectly good native word with a loanword. Second, the English language imported the word rucksack from German. We borrowed the word from you. Feel free to borrow it back; it was yours originally! And third, the import is disturbingly incorrect. In English, a body bag is a bag for carrying corpses, what in German would be called a Leichensack.

    This is a rather long and tedious set-up for my recent discovery. Apparently in Switzerland, the term for a light truck—not a semi-trailer but something that a family might own—is a Pickup, even though in English, the term pick-up is used only for a particular type of small truck.

    Mind you, the English language is hardly innocent in the matter of importing a word while changing its meaning. For example, the prefix über- (or simply uber-) is used in English to mean ultimate or super. As a random example, I produce this citation for the word ubermom. Of course, this prefix is nonsensical to native speakers of German, since über merely means over or on top of. The German word Übermensch, was originally translated into English as superman, leading to the widespread misconception that Über must mean super.

  • The Old New Thing

    Ruth Bader Ginsburg, the yardstick for Wikipedia entries

    • 55 Comments

    I use Ruth Bader Ginsburg's Wikipedia entry as a yardstick for other Wikipedia entries. At the time I'm writing this blog entry, her Wikipedia article is 1600 words long. So 1600 words is how many words Wikipedia assigns to the 20th most powerful woman (and the most powerful female lawyer) in the world.

    By comparison, Wikipedia has collectively decided that the 2007 Philadelphia Eagles season merits 5500 words. The exploits of a lackluster last-place American football team therefore clocks in at 3.4 Ginsburgs. In a sense, Wikipedia says that a last-place football team's exploits is over three times more significant than the most powerful woman lawyer in the world.

    The fictional character John Locke from the television program Lost comes in at 4900 words, or just above 3 Ginsburgs. Apparently Wikipedia thinks that it's notable that Locke likes Gold Toe socks.

    The plot summary for the movie Little Man is approximately 1.5 Ginsburgs. That's just the plot summary, not the entire entry. We know more about the plot to a mediocre film than we know about a Supreme Court Justice.

    It's not just popular culture that has taken the lead on Wikipedia. It's specifically post-2000 popular culture. The television program The Brady Bunch, which has been influencing United States popular culture for decades, merits a simple list of episodes, whereas the short-lived and totally forgotten show Studio 60 on the Sunset Strip spends 1300 words just on the subject of references from the show to other Sorkin shows.

    Even the Internet video The Bus Uncle weighs in at 1.8 Ginsburgs.

    Slate's Timothy Noah, who is certainly more notable than I am, also takes issue with Wikipedia's notability guidelines after being evicted from Wikipedia and subsequently reinstated. Reuters noted that the Wikipedia page is the new status symbol.

    For some reason I have a Wikipedia entry, despite not being "the subject of multiple, non-trivial published works from sources that are reliable and independent of the subject and of each other." As far as I'm aware, nobody has written even one book about me, much less multiple.

  • The Old New Thing

    Voicemail security, even stronger than bank security

    • 44 Comments

    Microsoft's telephone department takes security very seriously. Your voicemail password must be at least eight digits long.

    By comparison, the password for my ATM card is only four digits long.

    Because voicemail is that important, I guess.

    (Yes, I know about two-factor authentication. I'm writing this only half-jokingly.)

  • The Old New Thing

    Why is the fine for a basic traffic infraction in the state of Washington such a random-looking number?

    • 39 Comments

    Willy-Peter Schaub was puzzled by a sign reminding drivers that the fine for obstructing an intersection is $101 and wonders what the extra $1 is for.

    The laws of the State of Washington defer the monetary value of traffic fines to the Infraction Rules for Courts of Limited Jurisdiction (more commonly known as the IRLJ), specifically section 6.2: Monetary Penalty Schedule for Traffic Infractions [pdf].

    But wait, the fine listed in the IRLJ is only $42. Where did $101 come from?

    In addition to the base fine in the IRLJ, RCW 3.62.090 specifies additional assessments: Section (1) specifies a 70% assessment for public safety and education, and section (2) specifies an additional public safety and education assessment equal to 50% of the earlier assessment. On top of that, RCW 46.63.110 specifies various fees and penalties: Section 7(a) specifies a $5 fee for emergency services, section 7(b) specifies a $10 fee for auto theft prevention, section 7(c) specifies a $2 fee for the traumatic brain injury account, and section 8(a) specifies a $20 penalty to be shared between the state and the local jurisdiction.

    There are probably other clauses which add to the fines and penalties. I remember investigating this a few years ago and convincing myself that after taking all the fines and penalties and assessments and whatever-else-they-call-its into account, the total did come to $101. (Actually, they bring it to something close to $101, and then another rule about rounding kicks in.)

    And you won't get the numbers to add up to $101 any more because there were changes to the fee schedule in July 2007. The fine for basic traffic infractions is now $124. The new calculation appears to be 42 × 2.05 + 5 + 10 + 2 + 20 = $123.10, which rounds up to $124.

  • The Old New Thing

    Application compatibility layers are there for the customer, not for the program

    • 39 Comments

    Some time ago, a customer asked this curious question (paraphrased, as always):

    Hi, we have a program that was originally designed for Windows XP and Windows Server 2003, but we found that it runs into difficulties on Windows Vista. We've found that if we set the program into Windows XP compatibility mode, then the program runs fine on Windows Vista. What changes do we need to make to our installer so that when the user runs it on Windows Vista, it automatically runs in Windows XP compatibility mode?

    Don't touch that knob; the knob is there for the customer, not for the program. And it's there to clean up after your mistakes, not to let you hide behind them.

    It's like saying, "I normally toss my garbage on the sidewalk in front of the pet store, and every morning, when they open up, somebody sweeps up the garbage and tosses it into the trash. But the pet store isn't open on Sundays, so on Sundays, the garbage just sits there. How can I get the pet store to open on Sundays, too?"

    The correct thing to do is to figure out what your program is doing wrong and fix it. You can use the Application Compatibility Toolkit to see all of the fixes that go into the Windows XP compatibility layer, then apply them one at a time until you find the one that gets your program running again. For example, if you find that your program runs fine once you apply the VersionLie shim, then go and fix your program's operating system version checks.

    But don't keep throwing garbage on the street.

  • The Old New Thing

    Robots and humans coexisting, can it be done peacefully?

    • 37 Comments

    Everybody who follows science fiction knows that if you have robots and humans living in the same world, eventually something bad happens to the humans

    But we're going to chance it one more time.

    Every so often, I stumble across a Web site that translates my articles into another language. I occasionally see a Japanese translation, and I think there's a Russian translation out there somewhere. In addition to those human translations, there are also robot translations available through your favorite online translation service.

    Now the two can coexist.

    There's a new widget on this page which generates a robot translation, but there's more to it than that. Microsoft Translator's new Collaborative Translations Framework lets you suggest improvements to the robot translation, thereby helping the robot do a better job in the future. Visitors can view the translation alternatives and vote for the best one, and all this information gets funneled back to the Web site administrator, who can select one of the translations to be the one that appears by default the next time somebody asks to translate the page.

    And just because I'm so cool, the translation folks have provided a team of native speakers to act as the translation administrators for my Web site. That's good for me, because I am not really qualified to rate the quality of translations in French, or Spanish, or, um, pretty much anything other than English. (My understanding of German and Swedish gets me as far as identifying what is intelligible, but I don't claim to have a grasp of the subtleties.)

    Let's hope this doesn't destroy humanity.² (But if it does, at least your participation puts you on the winning side, right?)

    Footnotes

    ¹Probably because stories that go "Humans and robots work together, but then the humans turn off the robots" aren't as compelling.

    ²I'm pretty sure the Microsoft Translator team is not too happy that I'm suggesting that their invention may destroy humanity. Hey, I'm not saying it's going to happen. But it's possible.

    Bonus chatter: If you have questions about the Collaborative Translations Framework, you can ask them on the Microsoft Translator forum.

  • The Old New Thing

    Why does it take longer to reject an invalid password than to accept a valid one?

    • 37 Comments

    You may have noticed that it takes longer to reject an invalid password than to accept a valid one. There are a few reasons for this.

    First of all, it simply takes longer to confirm that a password is invalid.

    Your local computer retains a password cache. This password cache improves performance of local authentication operations, such as unlocking a workstation. If you unlock the workstation with the same password you used to log on, then the password is assumed to be good. This allows the workstation to unlock quickly. Without the password cache, unlocking the workstation would require going back to the domain controller to validate the password, which for slow network connections, can take a very long time. In fact, you might not have any network connection at all (an extreme case of slow), say because you've taken your laptop on the road and are not connected to the corporate network any more. In that case, without the password cache, it would be impossible for you to unlock your workstation at all!

    Note that you can disable these password caches if they offend you.

    The algorithm for testing if a password is valid goes like this:

    1. If password is in cache and matches: Return valid.
    2. Else contact domain controller for password validation.

    If you pass a valid password, then the validation succeeds at step 1. Notice that step 1 can be performed entirely on the local machine. It doesn't need to contact any other computers to get an answer.

    On the other hand, if you pass an invalid password, then we go on to step 2, which attempts to contact the domain controller to validate the password. Obviously you have to do this for passwords not in the cache, because you have no information about those passwords. But why do you also have to do this for passwords that are in the cache and don't match? Why don't you just say invalid without contacting the domain controller?

    Because your cache itself may be invalid.

    If the user recently changed the password on another machine, then the password in your machine's cache is not valid. If the user tries to use the new password, your computer's cache says, "Nope, that's not the right password." If you returned invalid immediately instead of contacting the domain controller, then users whose passwords have changed would not be able to use that password to access any computer which had cached the old password! They would have to sit around and wait for the old password to fall out of the cache, so that the computer would continue to step 2 and get the new password from the domain controller.

    You can imagine the bizarro technical support calls that would have resulted. "Yes, I know you changed your password, but you have to keep using your old password until the system starts rejecting it, and then you switch to the new password. And the rejection time will vary from computer to computer, depending on how many other people use the computer also. Oh, and if you're the only person who uses the computer, then it will never accept your new password. But once you log onto the computer with the old password, you might need to give your new password when connecting from that machine to other machines, because those other machines might have received your new password."

    Okay, so one reason why invalid passwords take longer to reject is that the computer has to try more things before finally deciding to reject it.

    Another reason why invalid passwords take longer to reject is to reduce the effectiveness of dictionary attacks. If invalid passwords were rejected just as quickly as valid passwords were accepted, then a bad guy could just churn through a dictionary trying out invalid passwords at high speed. Adding a delay of a few seconds before rejecting invalid passwords introduces a minor inconvenience to users who mistyped their passwords, but makes a huge dent in stopping dictionary attacks. For example (and these numbers are completely made up), suppose you have a 75,000 word password dictionary, and passwords are accepted or rejected in 100ms. It would take a little over three hours to attempt every password in the dictionary. Introducing even a simple 5-second delay into the rejection of invalid passwords increases the time to perform a dictionary search to over four days.

    The invalid password rejection time in some places can get quite high, especially if the delay escalates each time you get the password wrong. For example, after you type the third (fourth?) incorrect password to the Windows logon screen, it displays the incorrect password error for something like 30 seconds before letting you try again.

  • The Old New Thing

    First, try reading the error message, episode 3: Even programmers see error messages without reading them

    • 37 Comments

    As we all know, users don't read error messages. And, sad to say, this behavior extends to the group of people you would think pay the most attention to error messages, namely, programmers, who are the people who cause your computer to display the error messages!

    Today's example comes from an internal programmer's tool which I will call Program Q.

    I'm trying to back out an update I made to record 19 of our table (which was entered as transaction 512), but I can't get it to work:

    C:\> q backout 512
    Transaction opened for record 19 - must reconcile backout
    
    C:\> q commit all
    Transaction 520 created for 1 record
    Committing transaction 520
    Record 19 - must reconcile backout
    Unreconciled changes pending - use 'q reconcile' to resolve
    Commit failed -- fix problems above and then use 'q commit 520'
    

    What is the problem here, and how do I fix it?

    The transaction couldn't be backed out because somebody else made a change to record 19 since your original erroneous update, and the system wants you to reconcile this conflict.

    But that's beside the point. The point is that the user here merely saw that there was an error and didn't actually read any of the error messages. There were four error messages, and every single one told him what he needed to do!

    C:\> q backout 512
    Transaction opened for record 19 - must reconcile backout
    
    C:\> q commit all
    Transaction 520 created for 1 record
    Committing transaction 520
    Record 19 - must reconcile backout
    Unreconciled changes pending - use 'q reconcile' to resolve
    Commit failed -- fix problems above and then use 'q commit 520'
    
  • The Old New Thing

    Non-Microspeak: Boiling the ocean

    • 34 Comments

    Some time ago, MSN Careers listed Boil the ocean as a workplace phrase you should learn. Thankfully, the phrase (meaning "to attempt something impossibly ambitious") is not currently in wide use in Microspeak. However, a friend of mine who works in another industry tells me that it is not only very much alive in his line of work, it became corrupted as it was imported.

    My friend's industry involves companies from around the world, and although the working language for meetings is English, most of the participants are not native speakers of the language. He suspects that the phrase boil the ocean was introduced into the collective consciousness without a formal definition, and the company representatives at the meeting missed out on the impossible part of the definition, interpreting it instead as merely meaning to attempt something ambitious.

    As a result, at their meetings, you will hear people say things like "Let's try not to boil more than one ocean."

  • The Old New Thing

    How do I access the magic IEEE floating point values like NaN in code?

    • 33 Comments

    There are functions like _isnan, _isnanf, _finite, and _fpclass for detecting that a floating point value is one of the special values like NaN, but how do you actually generate one of these values?

    You can access these values from the std::numeric_limits template.

    std::numeric_limits<float>::infinity(); // positive infinity
    std::numeric_limits<float>::quiet_NaN(); // non-signalling NaN
    

    Wait, where's negative infinity? The compiler folks provided these handy little definitions for when you need to generate a special value (as opposed to merely detecting one), and for which the numeric_limits template comes up short.

    DECLSPEC_SELECTANY extern const float FLOAT_POSITIVE_INFINITY = ((float)(1e308 * 10));
    DECLSPEC_SELECTANY extern const float FLOAT_NEGATIVE_INFINITY = ((float)(-1e308 * 10));
    DECLSPEC_SELECTANY extern const float FLOAT_NaN = ((float)((1e308 * 10)*0.));
    

    Disclaimer: Applies to Microsoft Visual Studio. Your mileage may vary. Use the template when available.

    Bonus chatter: Note that you must use functions like _isnan to detect special values, because floating point special values behave very strangely in comparisons. (For example, NaN does not compare equal to itself!)

Page 1 of 4 (35 items) 1234