Had a disappointing weekend, where I brought my new computer to an all night quake gathering, only to discover my computer would not run quake!
After hours of forcing other people to swap parts of my computer into their systems, I gave up hope of figuring out what was broken. I spent most of the night playing SSX on a playstation someone had thoughtfully brought with them.
The next day, during a second marathon troubleshooting session I discovered that my ASUS A7V motherboard + GeForce 2 + Win2k were not playing nice. The reason I didn't discover it earlier, was that everyone else had a GeForce 2 too. I should have installed Linux. :)
Anyway, I bought a new motherboard. Now everything is fine and dandy.
And I must say, Cygwin has a pretty slick install program put togeather.
graydon:Yes, I think the right question is: "why isn't '() coerced to #f." More generally, why isn't the coerce-to-boolean form specialized for every type? The whole idea of everything being coerced to #t except for #f, in a way already violates the disjointness of types. If the system were totally pure, it would raise an error when anything other than a boolean constant is tested for truth. So, there is already a coerce-to-boolean form for each type; it just happens to be a constant function. I don't think it is any worse to define a more interesting coerceion function, different for each type.
Cognitive Illusions
I saw an interesting lecture yesterday on cognitive illusions in human/computer interaction; these are places where the mind incorrectly applys a hueristic to come up with a solution, instead of using logical thought.
One place this pops up is conditional probability. Write down the solution to the following problem before you check the answer.
Your friend has two rabbits. One of them is a girl. What is the probability the other one is a girl too?
For now, I've put the answer at the bottom of notes on my account page, because I can't figure out which of the allowed tags will make background black to do the hidden text trick.
Update: sarum is right, your friend wouldn't pick the rabbits randomly. So lets say, your friend has a rabbit that just had two children.
If you don't believe the answer, think about these other two problems, and how they are different.
There are two rabbits in a cage. The bigger one is a girl. What is the probability the other one is a girl too?
Update: and to clarify this one too, this question is not about rabbit physiology.
There are two rabbits in a hat. You pull one out, it is a girl. What is the probability the other one is a girl too?
Really tough to wrap your mind around, huh? If you still don't believe me, I'll make you a truth table.
Since Scheme seems to be a topic of discussion lately, maybe someone could answer a question for me.
Why is #f distinct from ()? For a language pushing minimalism, it seems unessesary.
Compare the following Scheme code to the same function in CL.
(define (breadth . trees) (if (null? trees) () (cons (map car trees) (apply breadth (apply append (map cdr trees))))))(defun breadth (&rest trees) (and trees (cons (mapcar 'car trees) (apply 'breadth (apply 'append (mapcar 'cdr trees))))))
BTW, that person that was pestering me for a homework solution kept calling and emailing me, up to the day it was due, but I think someone else gave them help. Sheesh!
just venting
hehe
I'm going to buy a new computer in the very near future.
I'm will be doing some Java programming, and I want to try out some of the new free IDE's. The ones that are written in Java themselves, are painfully slow on my Pentium II 233 w/ 128MB RAM. So...
The system I'm planning on putting togeather is:
Including the case, tax and shipping it's going to cost just over $900. Which I think is pretty good.
Update: I bought it all; spent $903 and change. Only I forgot to buy a fan, and you don't run an Athalon without a fan. Doh! So I've been using my same old computer, while I've had this kickass machine sitting on my floor for over a week. :)
Does anybody keep a collection of regexp code?
I recently had to implement a regexp
pattern matcher (but not for text strings) and I was
looking for something simple, without the unecessary
complications added by optimization. What I found
was:
Does anybody have any others?
deleted: incoherent dribble
New HTML Parser: The long-awaited libxml2 based HTML parser code is live. It needs further work but already handles most markup better than the original parser.
Keep up with the latest Advogato features by reading the Advogato status blog.
If you're a C programmer with some spare time, take a look at the mod_virgule project page and help us with one of the tasks on the ToDo list!