Skip to main content.
September 25th, 2005

migration underway

Ok, for those who haven’t been following along, the summary:

The official server status report is being kept on my general access university space at http://www.u.arizona.edu/~ammon.

Posted by Ammon as work at 10:59 PM EDT

No Comments »

September 20th, 2005

ほんとうのたからもの

Today marks the third time in living memory that Ammon has been brought to tears by a cartoon. The first was a result of the ‘baby mine’ scene in Dumbo when I was quite a young child. The second happened somewhere along the line when I was watching Ai Yori Aoshi a year or two ago.

Today, I sort of fast forwarded through scenes of Kimi ga Nozomu Eien. I think I might have only actually sat all the way through three or four of the fourteen episides. For some reason, the general emotional tenseness that pervades the series coupled with Mitsuki’s perpetual state of relative undressedness had the effect of preventing me from making any serious attempts to watch the show in its entirety.

So… I have managed to watch the first few episodes and the last few. I skimmed over everything in between, stopping when things looked funny or relevant to the plot. All in all, I don’t really recommend the show. That is to say, it is not required viewing. But it had an ending that had me fighting tears for about 15 minutes before I just gave in. It is too easy to relate to.

Posted by Ammon as sleep at 12:23 PM EDT

No Comments »

September 9th, 2005

questionable recruiting policies

Wow. Either somebody at Microsoft is playing a very cruel joke on their PHB or their recruiting department truly is lacking every possible shred of a clue. I like it.

Apparently, they just approached ESR as a potential hiree. The Slashdot article is here
and Eric’s rather entertaining response may be found on his blog here.

Posted by Ammon as eat at 2:43 PM EDT

No Comments »

force_ssl.php

<?
/**
* This heinously simple file just makes sure that anything that includes
* it is guaranteed to be connected via SSL :)
* - Ammon [9/9/05]
*/

if( $_SERVER['SERVER_PORT'] != 443 ) {
    header("Location: https://".$_SERVER['SERVER_NAME'].$_SERVER['REQUEST_URI']);
    die();
}
?>

Posted by Ammon as work at 2:11 PM EDT

No Comments »

September 8th, 2005

the array of hope

An old friend from TAMS sent me this url today. It links to a particularly ... horrid example of programming practice. Our conversation follows.

(15:40:34) Matt: must... not... look...
(15:40:52) Ammon: huh?
(15:41:00) Matt: (look ;-))
(15:41:29) Ammon: ...
(15:41:34) Ammon: _wow_
(15:42:00) Matt: hooray for exceptions
(15:42:05) Ammon: that's just obscene
(15:43:13) Ammon: ... it
(15:43:17) Ammon: it hurts my soul
(15:43:27) Matt: deep down, where the pie goes?
(15:43:28) Matt: yeah
(15:43:32) Ammon: yeah

The code in question (for those who don't want to follow the link)?

try
{
  int idx = 0;
  while (true)
  {
    displayProductInfo(prodnums[idx]);
    idx++;
  }
}
catch (IndexOutOfBoundException ex)
{
  // nil
}

I don't know if I really want to explain what's wrong with this for those non-programmers who might be reading... No. I don't. But I will anyway.

Since time immemorial, the most common way to iterate over an list of values has been to use an index variable that is incremented until it reaches the size of the list. And then you stop. And you don't continue to look at things. If you try to look beyond the end of the list, strange and unpredictable things can happen - exactly what happens depending on the system involved.

This program ... does an infinite loop, increments its counter, and then crashes when it runs past the end of the list of product id's to be displayed. But, it plans on crashing. So it knows to just ignore the disturbance in the Force that is generated and continue running despite the millions of souls crying in agony before being silenced by the idiot programmer who is being paid to murder them in their sleep.

Posted by Ammon as work at 3:54 PM EDT

No Comments »

« Previous Entries