The trends

Alfons Cancer and Google Trendslinked to a PDF that contains the musical score of Ives’ ‘The Unanswered Question’. I can’t link to it right from here (I get a dreaded message saying something about “This is the second IMSLP image server”) but it should be around the previous hyperlink. That said, I’ve not seen the IMSLP site before, so if you’re into transcribing music with (for example) your SonicCell… think of me. (And before you click that SonicCell link: no: I don’t get paid for that. I just have good memories when I think of Roland soundcards)

I was following the grilling of Gonzales and was particularly stunned by the reaction of Sen. Schumer (video 1, video 2) upon hearing some of Gonzales questions. Disbelief (metafilter thread).

And then, for no particular reason, I decided to look up Google Trends for ‘cancer’ and noticed that there was no spectacular increase of searches for that particular word. Both my (our) parents died of cancer and yet, there is no cure for this disease (note: photos might be heart-rendering). Well, maybe there, is but then I read:

(the) Antisoma’s chief executive, said he was “very confident this would be a blockbuster product with the potential for strong sales”

Maybe I just picked out the wrong quote. Yeah, yeah, yeah.

Posted in We-reflect-news | Tagged , | Comments Off on The trends

Cards

For something completely unrelated, I decided to check into my older Delphi code and noticed the ‘remnants’ of the code that actually started as a framework for a (basic) Spades1 card game. So hey: the code was actually so readable that most of it was easily turned into a C# version (that is minus the bidding code).

The fun part of it all was the ease of sorting in C#. Actually, you still need to write code to get that going, but compared to the things I needed to get a hand sorted in Delphi, that can be a different story (it’s actually not too bad either if you use regular TLists and that):

First of all make your base object descend from the IComparable class. This means, you’ll have to add a CompareTo method to your base object

 public class TCard : IComparable
    {
        private TFaceValue ffacevalue;
        private bool ffaceup = false;
        private TSuit fsuit;
        
        // Code removed for brevity reasons...

        public int CalcValue
        {
            get { return NumericValue(); }
        }

        public int CompareTo(TCard acard)
        {
            return this.CalcValue.CompareTo(acard.CalcValue);
        }
    }

Then create a class based on IComparer:

    public class THandComparer : IComparer
    {
        private TSortOptions fsort = TSortOptions.Ascending;

        public TSortOptions SortOption
        {
            get { return fsort; }
            set { fsort = value; }
        }

        public int Compare(TCard x, TCard y)
        {
            if (fsort == TSortOptions.Ascending)
            {
                return x.CompareTo(y);
            }
            else
            {
                return y.CompareTo(x);
            }
        }
    }

I decided to give the player an option to sort the cards descending or ascending based on the combination of suit and card value: Notice that for descending order, you literally just switch the objects (the base CompareTo method returns -1, 0 or 1!)

And then in the THand Class:

 
        // [....]
        public void Sort()
        {
            THandComparer fcomparer = new THandComparer();
            fcomparer.SortOption = forder;

            fhand.Sort(fcomparer);
        }

What rest are the drawing procedures, the card faces (I should have a couple of sets somewhere on my source backup disks) and the bidding engine.

1 I find it amazing that Pagat once again serves as a reference for card games, just like it used to do back in 2000.

Posted in Programming | Tagged | Comments Off on Cards

More computer stuff

It’s a kind of a miserable day over here, which is right in time for some more miserable updates. I read for example that Microsoft is going to retire Windows XP in 2008, which means that OEMs will be forced to install Windows Vista on new PCs. Related: Vista Express Upgrade nightmare.

Earlier, Microsoft released a couple of Developer SDKs for their Windows Home Server. Windows Home Server (as the name implies) is Windows XP for well, home servers. This is old-hat for people who have been running (for example) desktops as Linux or BSD servers. I have been looking for a replacement for my Debian-based server, particularly I’ve been looking at mini-factor form cases that (guaranteed) consume less than 100 Watts. Yes, they do exist. Look at that! That said, the only part that makes Windows Home Server attractive is that SDK. (uh-oh: leak).

Apple’s forthcoming Leopard edition of OS-X has been delayed too, and the consensus in the media is that this is good news because of upcoming new secret features in that OS.

Earlier, LifeHacker showcased the top 10 Life Saving System Recovery tools and yes, it includes Knoppix. Alfons demoed Knoppix in early 2003 after one of my Windows computers suddenly broke down and refused to start up appropriately. We managed to copy data off it and converted the PC to either Fedora or Debian Woody.

Oh dear: A confession from Halle Berry that she ‘anonymously joined internet chatrooms to escape her famous persona’:

“I was just trying to chat anonymously and just be another person in the chatroom having a conversation. When I decided to say: ‘Oh by the way, the person you’ve been chatting with for a week is me, Halle Berry,’ they thought I was just some kook”

To that I can only say: “I’v3 533n yu 1n 4 J4m35 B0nd m0v13. LOL ROFLOMGZ!11”1

Posted in Ordinateurs | Tagged , , , | Comments Off on More computer stuff

Debian 4.0 & the other updates

So, after 21 months of development, it seems that Debian “Etch” 4.0 has been released. Which means that I have to get my jigdo-tools out of the safe and start downloading the CDs again (earlier on xsamplex). (There are also other ways to get your favourite Linux distro, but I personally have had good experiences with Jigdo).

If you’re not sure how Jigdo works (under Windows), download the tools from here (Atternet’s) and extract them to a directory of your liking. The next step is to get the right jigdo-file, which depends on which hardware you plan to run Debian on. Most likely that will be i386 (also pick which type download: CD-Rom/DVD). For the rest it’s just following the steps and have it run in the background, while you (so to speak) update your MySpace spot.

Right behind last week’s patch (re: anicursor security thing), Microsoft released a hotch-potch of other security patches. You can find them (and the details) at the regular location (and the other website I keep forgetting to mention).

That reminds me: I read Paul “Bayesian Spam” Graham’s post called ‘Microsoft’s death’, which caused a firestorm of follow-ups. I think I’ll keep the link fury limited by only pointing to Slashdot’s thread. I’ve never been a fan of Graham but reading his notes reminds me of my earlier claims that Microsoft is doomed to fail not because Linux this or MacOSX that: it has consistently failed to deliver. There were days that the company came out with something that was worth checking out from both user and developer’s view: nowadays, there’s only a handful of technologies that are actually interesting from a developer’s point of view. It will be interesting to see if they can turn the tide this year (particularly after [what appears] a botched Vista release).

Posted in Hyperlinks, Ordinateurs | Tagged , | Comments Off on Debian 4.0 & the other updates

Snow@easter.night.com

If there was something like ‘Easter Night’, then it looks like Christmas outside. Snow that is and while this was obviously part of today’s forecast, it took me, dog and the snow plow drivers by surprise. It should be gone by tomorrow, I hope, but then temperatures are still hovering around the -3 to +2 degrees Celsius. What do you mean, it’s almost already Spring?

Talking about Easter, over here Good Friday is generally a statutory holiday. North Americans have never heard of ‘Second Easter Day’. If you live in a country that celebrates a ‘Second Easter Day’, consider yourself lucky.

Did you know that the calculation for the date of Easter is quite hard? The good news is (or was, historically speaking) that a well-known mathematician, Carl Friedrich Gauss, already came up with an algorithm. Literally, food for statistics:

In the Western Church, Easter has not fallen on the earliest of the 35 possible dates, March 22, since 1818, and will not do so again until 2285. It will, however, fall on March 23, just one day after its earliest possible date, in 2008. Easter last fell on the latest possible date, April 25 in 1943, and will next fall on that date in 2038. However, it will fall on April 24, just one day before this latest possible date, in 2011.

Mark down 2038 in your daily planner.

04/08/07 – update 1: The snowstorm is actually worse than I thought, which means digging out by noon (that is if the wind doesn’t let go).
– update 2: The news at CBC.
– update 3: What do they mean, ‘no weather warning in effect’ for this area?

Posted in Hyperlinks, Truro NS | Tagged | Comments Off on Snow@easter.night.com

Psychic Defense vs. Air Guitar

Stop staring right now:
my wicker carpet beater
plays like a guitar

Posted in Haiku | Comments Off on Psychic Defense vs. Air Guitar

Daylight Savings

A couple of days I was reading about the energy saving component of the US Energy Policy Act 2005 (Wikipedia), the extension of DST by 4 weeks (earlier on xsamplex). Apparently, power companies in the US didn’t notice a big change.

“There might have been a small increase in morning lighting, and a slightly larger decline in evening lighting usage,” said a spokeswoman at New Jersey utility Public Service Enterprise Group Inc, “but that modest decline will have no impact on its overall sales or earnings.”

What was Congress thinking?

This also reminds me that when I was over in The Netherlands, it appeared to be getting darker sooner than over here in Nova Scotia. Thinking of that, it reminds me of a comment Alfons made when he was over here the very first time, saying that “The light is so bright over here”.

Posted in Hyperlinks | Tagged | Comments Off on Daylight Savings

That didn’t work

Windows Update downloaded the latest security update (KB925902), but after restart I got the folllowing error message:

RTHDCPL.EXE – Illegal System DLL Relocation. The system DLL user32.dll was relocated in memory. The application will not run properly. The relocation occurred because the DLL…

Alrighty!!! A patch gone wrong, apparently. On today I guess, the same day they released that security patch, Microsoft issued a hotfix (KB 935448). Notice that you may get errors while getting to the actual download: it appears that this fix is quite popular. If you run a RealTek card, you probably ran into the same issue. Particularly, if you own a Toshiba laptop.

Oh: and talking about patches, you may also consider updating your WordPress (see also here for more details).

04/04/07: Slashdot discusion.
04/11/07: A weeks later, the issue brought up over at the BBC.

Posted in Ordinateurs | Tagged , , , | Comments Off on That didn’t work

Pyramids

Via (the always excellent) 3 Quarks, a new theory how the Great Pyramid was built. The original site that hosts a video and 3D animation (from Dassault Systems) requires an extra plugin (3D Life player), which also works on Firefox (Windows). If you’re not into plug-ins, you can also download the PDF.

2K Games announced a new Civ IV extension pack (previously on xsamplex), which includes:

New Civilizations: The expansion pack includes ten new civilizations, such as Portugal, Babylon and Netherlands and their associated unique units and buildings.

Oh dear.

Via Digg, I found this video of an interesting way of using your fingers as a mouse with the help of a camera (4:45 minutes long). The interviewer is a douche bag, yes: if you listen carefully what the programmer is trying to explain, much of it will make sense. Not revolutionary, but yes, an interesting approach to tackle this specific problem.

If you were ever into fractals (and I suppose, every programmer or nerd would have been), there’s this amazing movie of a quite deep zoom into a Mandelbrot. It keeps going and going, so to say. The first time I saw a fractal to be drawn (on an MSX-2), it took a full day to finish it. With a cluster of PS3s…

Fractint. And earlier on xsamplex.

Posted in Hyperlinks | Tagged , | 2 Comments

Back & Subtitles

Yesterday, I found out that the History Channel was showing ‘Das Boot’, which is one of the movies I can watch a multiple times in a year (earlier). Let me guess: in the Summer of 2007, History Channel will repeat this movie as part of their ‘Submarine month’. That said, I start to get pissed off at ‘subtitles’. This is good in a way.

This morning, it also appeared that ‘April Fool’s day’ was full in effect. One of the best ones was this WiiMote, only because I’m still not sure if it is joke or not. It will work ofcourse, but it’s a ridiculous idea. Brilliant. On the other hand ‘GMail paper’ is brilliant too.

Consider this: in another 10 years, only computer users will be celebrating this particular day because it’s easier to prank other people online than it is in real-life.

Posted in The Chest Desire, Truro NS | Tagged | Comments Off on Back & Subtitles

TenSpeed

I learnt Ten Speed and Brown Shoethat Jeff Goldblum is starring in a new TV show, ‘Raines’. I think the show is on NBC, every Friday night. I read the show is about, wait, let me pull a quote from the site mentioned earlier:

Eccentric LAPD Detective Michael Raines (Goldblum) uses his unique imagination to focus on every murder case in such a way that the murder victims actually begin to take shape in front of him. At first, he thinks he’s losing his mind, but he then uses the constantly evolving hallucinations — which are figments of his imagination and not ghosts — to help him discover the victims’ killers.

For some kind of reason, that sounds like the kind of role Goldblum has been playing for ages, like for example, in the show ‘Ten Speed and Brown Shoe’ (1980). I bet a lot of people don’t remember that show, but, when I hear Goldblum’s name mentioned, it’s that show that I always associate him with (and of course the movie ‘The Fly’). If I’m not wrong, this show also showcased Goldblum’s character’s amazing bookreading skills.

Posted in The Chest Desire, Those-wonder-years | Tagged | 8 Comments

Rainbow Six 3: Raven Shield

I was Attack! Attack! Attack!so bored, that I decided to look in my CD collection for older games: I fished out Raven Shield, a game I think I bought in 2004 (originally released in 2003 by UbiSoft). If I’m not wrong, back in 04, I almost finished the game, but (for some kind of reason) decided to dedicate my time to something more important.

Since the hardware has upgraded since 2003, this time, I was able to set all graphic settings to the maximum: including the gore one. After quickly familiarizing myself with the controls (making slight changes to mouse settings [fast] and different key-bindings for zoom and direction keys) during the perfect training sessions, I jumped right into campaign mode.

If you have played other Rainbow Six games before: these kind of games require a lot more strategy than the average ‘bash and crash through doors and kill everything that is in the way’ – games. Rainbow Six, for example, comes with expansive team control: portions of the game include planning, which (if you feel like it) allows you to set the waypoints manually and assign the individual team members to execute the missions. The good part is that each mission comes with 2 default plans, which are generally good enough to make it through the whole mission. Slightly confusing, however, during gameplay you can switch players and teams. Switching teams can be handy if the other team is taking too much ‘enemy fire’, which may (or may not) force you to take over command of that team. There are many weapons to pick from, too, not to mention that some team members have specific talents for (you guessed it) specific missions.

That said, in-game flow is good: it’s generally well-balanced. Some missions are tough which makes you curse why there’s no ‘auto-save’: if your team(s) die, you have to start all over again. ‘Enemies’ react fairly smart and will kill hostages if they detect one of your team members or teams. They react to noises too and will vehemently defend their (assigned) locations.

So is it good? Yes, albeit frustrating at times. If you get hit, you’re generally dead (‘start over’). Your enemies don’t always start (spawn) at the same spot, which can lead to surprising turns during the mission. But for an older game, it still stands the test of time and is actually enjoyable on nowadays faster (and better) computers. On my frustration-level, I would give it a 6, which means that “It’s sailing, but the motor ran out of fuel and there’s a big chance we may need to use the wooden peddles. Whatever”. That’s as close as a get, if you’d ask me to explain the game. However, without a doubt, if you see this game in the 10 dollar bin, I’d say ‘go for it’.

Posted in Video Games | Tagged | Comments Off on Rainbow Six 3: Raven Shield

Lazy.

I read that A genuine garbage collectorJohn Backus died at age of 82 (Slashdot discussion), who happened to be the person who apparently led the team of developers that brought us FORTRAN.

I recalled his name because I was studying some BNF notations of several languages (described in this post). If you’re not sure what BNF is, well, try Wikipedia again.

There’s an interesting (and hilarious) quote from Backus:

“Much of my work has come from being lazy. I didn’t like writing programs, and so, when I was working on the IBM 701, writing programs for computing missile trajectories, I started work on a programming system to make it easier to write programs for the 701.”

I hear productivity went up after his crack team of developers released the first version of FORTRAN. Which reminds me that a good developer is lazy in the sense of ‘why do things manually, if I can write a program to make that problem go away faster’. This also reminds me of the way how easy it is to create objects in C# without even thinking of properly disposing them because, well, the garbage collector does that automatically for you (or I should say, this applies to any language that uses a garbage collector). It almost makes me long to Delphi, just to feel less lazy.

Or maybe, I mean, less helpless: I mean, these objects, can I please make them dispose?

Please?

Posted in Ordinateurs, Programming | Tagged | Comments Off on Lazy.