KBD

Keith Devens .com

Saturday, October 11, 2008 Flag waving
The direct pursuit of happiness is a recipe for an unhappy life. – Donald Campbell

Archive: February 24, 2003

← February 23, 2003February 25, 2003 →

Daily link icon Monday, February 24, 2003

Why Saddam will never disarm

A good article floating around the web today. Via InstaPundit and LGF, Why Saddam will never disarm.

I'll just quote Reynolds:

Keep this in mind: Saddam will do whatever he can get away with.

And France, Germany, and the "peace movement" want him to get away with everything, because -- for reasons of their own that vary -- they'd rather see that than a war.

Keep that in mind when you hear Chirac say that "inspections are working." They are working -- for Saddam, and for Chirac.

640k ought to be enough is a legend

If this Slashdot post is accurate (don't laugh), then Bill G never said that famous line.

Tom Lenk rules

I love Tom Lenk. Andrew really has been one of the best parts of this season of Buffy. The beginning of last episode "This funnel cake is kicking my ass" was awesome. Turns out tomorrow's episode will be "Andrew-centric", so hopefully it'll be fun. Anyway, there's an interview with him (via WHEDONesque) that's worth checking out.

You may also be interested in reading this article on Buffy (also via WHEDONesque) about how it breaks TV conventions and why that makes it one of the best shows on TV.

Update: here's a TV Guide interview with him, via WHEDONesque

How to interview a programmer

Via Artima.com, How to Interview a Programmer:

Throughout this discussion, one theme was clear: good code is written by good programmers. Therefore, one great way to improve the code quality within an organization is to hire better programmers. The trouble is, recognizing a good programmer among a pool of job applicants is not easy.

Finding good programmers is hard because good programming is dependent on much more than just knowledge of programming language syntax. You need someone who, despite wearing striped pants with a polka dot shirt, has a good sense of taste in OO design. You need someone who is creative enough to find innovative solutions to problems, yet anal retentive enough to always line up their curly braces. You need someone who is humble enough to be open to suggestions for improvement, but arrogant enough to stand firm and provide leadership when they are the best person to provide it. How can you tell all this about a stranger by spending 30 minutes with them in a conference room?

The final morning of the Writing Better Code summit, Bruce Eckel announced he was "hijacking" the meeting. Bruce wanted each person at the table to share his or her interview techniques. He wanted to know how we recognize a good programmer in an interview. In this article, I highlight some interview techniques discussed that morning.

God I hate PHP

PHP is one of the worst languages in use today. It's OO is so badly broken that I've been swearing all night at it. At one point tonight I thought what I've been trying to do would actually be much easier in Java!

Objects keep getting copied when I don't want them to, and I spend so long staring at it trying to figure out where that is. Some of my code even looks like this:

$p = &new StParagraphRecognizer($this);
$b = &new StBlockquoteRecognizer($this);
$t = &new StTextRecognizer($this);

$this->recognizers = array(
ST_PARA => &$p,
ST_BLOCKQUOTE => &$b,
ST_TEXT => &$t
);

just to avoid making copies, because you can't say something like ST_PARA => &new StParagraphRecognizer($this). Damn you PHP.

Update (2/25): It turns out (via a comment on the appropriate page in the PHP manual) that if you have your constructor always return a reference you can avoid having to do this. I haven't verified that this works, but it seems like it would. It doesn't change the fact that PHP's OO is fundamentally broken. In PHP 5 (with the Zend engine v2) PHP's OO will be more "normal" (i.e. more like Java), where objects have reference (pointer) semantics by default, and you have to copy explicitly (there're also other nice things built in).

After reading this, I'm wondering if I could find a host that has good support for Python, and switch over to that. There are lots of PHP-like solutions in Python (that link is just one among many). I don't know how they compare to PHP speed-wise, but anyway...

Update: It turns out there's a page in the manual that refers to this specific problem.

← February 23, 2003February 25, 2003 →
October 2008
SunMonTueWedThuFriSat
 1234
567891011
12131415161718
19202122232425
262728293031 



RSS feed RSS feed for Keith's Weblog
Atom feed Atom feed for Keith's Weblog
Weblog archive
Recent comments
  on 7 posts

Recent comments XML

new⇒I hate PHP

Elliot Anderson,

Dude!! You the​man! The reverse replacement for​array_u...

Alex Ndungu: Oct 11, 1:35am

Call a function from a string in Python

?!code:
some_object.__getattribute​__('method_name')()
?!/code

is​the s...

Patrick Corcoran: Oct 8, 3:53pm

Spider solitaire

I have won 185 games of Spider​Solitaire at the "Difficult" level.​ What is...

75.179.28.113: Oct 8, 12:42pm

Sed one-liners

Hi.

I wanted to let you know​that I wrote an article "Famous Sed​One-Lin...

Peteris Krumins: Oct 8, 3:05am

Timesheet Calculator

Hadn't seen it before now, but my​company already uses a time​tracking prog...

Keith: Oct 7, 10:44am

Girls, please don't get breast implants

Hey everyone, 

I am new to this​blog and I have enjoyed reading all​your...

Sarah.M.: Oct 6, 9:45am

Generated in about 0.06s.

(Used 7 db queries)

mobile phone