JPPPP

Here's Yet Another Bad Practice That Makes Me Wince Every Time I See It:

when people use setup as a verb, when they should write set up -- two words.

Other things are similar, but not quite as ubiquitous. E.g. "everyday", as in the ridiculous "floss your teeth everyday".

And WTF is up with "albeit"? Last Saturday was bizarre. I read like half a dozen articles (both on line and in print) in a row, and every single one used the word "albeit". The RNG in the Matrix needs a good thump, or something.

the golden rule ain't so...

I mean, it may be great for kids, when you're trying to socialize them. But for adults, its usefulness is pretty limited.

The problem is the premise: it works if we all want the same thing. But we don't. We all want different things. So if you want to be nice to someone, don't treat them the way you would want to be treated; treat them the way they want to be treated.

This came to me as I was pondering a recent thread on an email list, in which two people expressed entirely opposite viewpoints on the issue of "courtesy copies". One person finds them annoying, and so he always trims out all addresses from To/Cc except for the email list; the other person thinks they're useful, so he leaves the other addresses in. They're both following the Golden Rule, and in the process, hurting each other. The Golden Rule has backfired.

Of course, in a situation like this, things aren't so black-and-white, since there are the other members of the list to consider. Both individuals are serving the interests of some fraction (roughly half?) of the community, so it's not like either one should necessarily be enjoined to reverse his behavior.

Wednesday July 10, 2002

10:31 AM

tcl and smalltalk

Believe it or not, reading the perl6 summaries (thanks, pd!) has gotten me to look at other "meta-compiled" languages, in particular, Tcl and Smalltalk.

I have to say, I really like the semantics of Tcl (the source-level language) (though the syntax is perhaps slightly less than ideal), and I really REALLY like the execution semantics of the smalltalk virtual machine. But the syntax of Smalltalk is heinously hideous! I wonder if there are any other languages that have back-ends targeting the smalltalk vm? I almost wish the perl6 guys had considering using the smalltalk vm, at least as a starting point. So much good work has already been done on virtual machines, and I'm not convinced that reading a few papers is enough to allow one to say that he is not reinventing the wheel.

Thursday June 27, 2002

11:34 PM

doodling...

Well, I finally decided that it has been waay too long since I put a module on CPAN, so went about making one that I've been thinking about for a while.

Basically, sometimes you want to do something with one of several arrays (or hashes) based on some discriminant. For example, you have have a list of filenames, and you want to stick all the file names in one array and directory names in another. Ordinarily you might do this:

The first argument after the the tie class name is a sub-ref which is called by the object to get an index value. The next argument is an array(ref) of array-refs. The result of calling the sub is used to select one of the arrays in that anonymous array. In the above example, -d returns either true or false, which get converted into numeric (0 or 1) for indexing into the array.

You could have more than two, and you could have a hash of arrays instead of an array of arrays:

this program

We had this nasty old perl program floating around, and when I looked into it, I could not believe the insanely bad programming. I'd like to say that the programmer was a converted Fortran hacker, but that would be too generous. I can't even assume that this programmer learned how to write perl by looking at Matt's Scripts. It's more like, he selected about 1 in 5 random lines from perltut, and kept only those bits that worked without modification. As a result, the only array operations he knows about are:

for ( @a )

@a = <F>;

$a[$i] =...

That's sure not much to go on.He didn't even know how to assign a list to an array. He thought the way to initialize (or "blank out") an array was with

$a[0] = "";

WTF?!!!

He also didn't know about push. In order to add an element onto an array, he would do the following:

moz

So I've installed Mozilla 1.0 on my stupid, consarned Windows box here at work (interestingly, my company has mandated the use of Windows (NT4) and Microsoft Office crap -- "All documents shall be in Word format" -- for most things... but then, "Thou shalt not use IE, but rather, Netscape").

Well, Netscape was giving problems, acting flaky, and IE, while sufficient in a pinch, was leaving a very bad taste in my mouth. So I went searching for a Better Browser. I've tried Opera in the past, and though it has some niftiness, it's also not open source. And then I heard that Moz1.0 was out, so I tried that.

Mozilla++

Mozilla rocks! On Windows at least, it is very slick, full featured, and stable. It also allegedly handles the latest in web standards correctly. Woo hoo!

Bad dream last night

Do you remember, back when the U.S. Marines were deployed in Somalia (as in Black Hawk Down), we heard stories on the news about the use of a drug in Somalia called khat, a leafy plant that is chewed.

Well, for some reason, my unconscious mind decided to make that the basis of a terrible dream last night.

<dream>

Apparently some marines, or other persons deployed to Somalia, had brought back with them khat plants to the U.S.

Then, someone figured out a way to isolate and purify the active ingredient, a powerful narcotic which in its natural state is extremely dilute.

Addiction is becoming epidemic. The use of this drug is accelerating so rapidly that the legislative bodies have not had time to outlaw it.

This drug is distributed and consumed in the form of a clear, colorless syrup. It is administered orally. It is not swallowed, but is held in the mouth, to be absorbed through the mucus membranes.

The user can take one or two spoons of the syrup himself, but then quickly enters a stupor. After that, someone else administers the drug, dripping it (like honey) into the user's mouth. After just a few more spoonsful of this stuff, the addict begins to sieze. Scenes of this drug use (parties) have several people with mouths agape, clear syrup running down their chins onto their clothes, convulsing and unable to sit upright.

And yet, there appear to be (so far) no lasting detrimental effects. No known instances of death amongst the addicted population, no cases of someone emerging from their stupor with half their previous I.Q. And everyone insists that the drug produces very pleasurable feelings in the mind, and they all want to do it again, despite the rather unpleasant appearance of its consumption to others. Physical addiction is instantaneous, and psychological addition almost so.

JPPPP

On the evening news, when they're talking about some recent local crime (for example), you'll hear the idiot reporter say things like:

The suspect then smashed through this window, out into the alley; witnesses say the suspect then jumped in a car and sped away...

What's wrong here? It is not the suspect who did these things, it is the perpetrator.

People seem to have forgotten about the word "perpetrator", and consequently the critical difference between a perpetrator and a suspect.

A suspect is a person whose identity, or some other personal info, is known, and who is thought -- though not (yet) known -- to have committed the crime. The perpetrator is the person who did, in fact and in actuality, commit the crime, even if nothing about him/her is known at all. The perpetrator is the person who is truly guilty of the crime, even if never identified, caught, or tried. A suspect is someone can be identified and caught, and yet who is presumed innocent until proven otherwise in court.

Friday June 21, 2002

03:16 PM

Eggplant rulz

I've decided that eggplant is about the yummiest thing in the whole wide world. I could eat it every day. Jen sorta got me started on it, with this Persian stew (khoresh-e bademjan), but other forms are good too. Like eggplant parmesan. And bengan bharta. And baba ganoush. And imam bayildi.

journal

Seems like some people actually use their journals to write down what they're doing that day. I suppose I could give it a try...

I'm going for a hair cut tonight. First time in months, and man am I overdue. Jeni has decided to let me get a color this time (after years of pleading). Probly because she has a coupon for it.

Did anyone watch American Idol last night and the night before? I was very skeptical at first, because it was such an obvious rip-off of Pop Stars. (Fox copying WB. Imagine!) But it turned out not to be.

One thing that was cool was that the show was broadcast live. LOTS of unscripted moments. I can't believe how awful some of the contestants were, at this semifinal level. That girl Rhodesia... words can not describe. What the hell was she thinking, with "Daydream Believer"? Anyway, there's no way she could win, because not only must they have vocal talent, and showmanship, but they have to have The Look. That rules out a lot of people, including people with talent.

My fave: Ryan Starr. The girl can obviously sing. I bet she really could sing anything thrown at her. Also I have to give her extra marks because she looks *exactly* like one lover from the days of my youth, and also a lot like another sweetheart of not so long ago.

Jeni and I are planning to go see Norah Jones in concert tomorrow night at the 9:30 club. Now there's a girl with talent. Diana Krall WISHES she could sing half so well as Norah Jones.
Norah Jones++
Diana Krall--