Archive for the 'Uncategorized' Category

Python vs Java

9 August 2012

I have to think about whether we’re going to use Python again next year for ICS3U or whether we’re going to revert to Java. The move to Python was initiated by Boy. He had polled some Comp. Sci. profs at Carleton U. They were pretty clear that they would prefer to see students coming in with Python. I was crazy busy at the time and just said  “Go ahead. Whatever.” I came to regret that (non) decision, however, when I was subsequently teaching the course myself and had to re-work all my powerpoints and assignments into Python – not to mention learning the language on the fly as I taught it. But that’s mostly done now. The only gaping hole in my Python understanding is in GUI stuff. That shouldn’t be too hard to remedy.

OK. So where do I stand on all this?

I can see why Python is a good intro language for programming. Students can get up and running pretty quickly. If they have a moderate degree of aptitude, they can do stuff fast. And that’s a good thing. Why should they be hobbled by the grunting mechanics of a language (declare before use, rigid data typing, etc.) when that’s not necessary.

Still, I ran into some problems going through the course for the first time in Python and they didn’t have anything to do with the P.I.T.A. of converting my stuff to Python and personally having to learn the language. In a way, Python is too powerful. It’s like teaching someone to drive in a Ferrari. They can do a lot quickly. That’s for sure. But they can go too fast, too quickly. I spent a lot of time sorting out issues having to do with data typing. Students create a variable that they intended to be an int but they would get a value for it from stdin using raw_input. Fair enough but you can’t then turn around and use the variable as an int without converting into an int first. (raw_input always returns a string.) In v. simple problems this wasn’t much of a problem to figure out. When the programs started to get longer then tracking down what was going wrong could get difficult. They wouldn’t have had this problem in Java. The compiler would have flagged  the issue right away.

The other big issue I had was that Python made it really easy to write disorganized programs. Liberal declaration rules made scoping problems easy to miss. Students had a really hard time seeing that myInt in the main program was different than myInt in a function they had written. And Python’s use-right-away declaration policy meant that initializations were spread all over the place. Indeed, the whole notion of initialization was fuzzy. Even in Python it helps to make a point of initializing variables  and using them later but it takes a lot longer to see the value of it.


The Watcher

22 February 2010

When I wake up in the morning I can often feel or observe my ego-mind kicking in. I tense up as that part of me swings into action, criticizing something I’ve thought or just remembered that I’d done or worrying over something that’s going to be happening in the upcoming day.

It happens most clearly on Monday mornings, when the school week is about to start.

It seems to be the case that the job of this part of me is to pre-plan how I’ll deal with problems. This sounds productive but the end result is that scenario after scenario gets pre-filtered and pre-pared and pre-chewed and that I’m never comfortable just encountering my life. Even the part that deals in extensive self-criticism is involved in the this management task. I criticize myself so that I can be prepared for the criticism that I fear might be directed at me.

Philosophy; definition of

7 December 2009

Philosophy is the radical pursuit of the reality masked by convention. From 3quarksdaily.

Security and Surveillance

18 August 2009

“It’s bad civic hygiene to build technologies that could someday be used to facilitate a police state. No matter what the eavesdroppers and censors say, these systems put us all at greater risk.  Communications systems that have no inherent eavesdropping capabilities are more secure than systems with those capabilities built in.” – Security Expert Bruce Schneier.

Taking the anti-abortionists seriously

5 June 2009

Slactivist has a very salient point to make about the right’s response to the murder of abortionist Dr. George Tiller by Scott Roeder. They roundly condemn the murder and for all intents and purposes are horrified by it. But the truth of the matter is that they liken abortion in America to the Holocaust and people like Dr. Tiller to Nazis running death camps. If that claim is true then Roeder’s killing of Tiller is the logical and, frankly, moral outcome of the claims to be true. If abortion in America is the same as the Holocaust one does indeed have duty to stop it by means considerably more forceful than voting for the Republican Party every four years. The fact that they (the right) is shocked by Roeder’s murder of Tiller only shows that they really don’t take themselves seriously. If they did, they’d have to count it as a victory that Tiller was murdered. But they don’t and that means that the anti-abortion talk is at best disingenous – a convenient rhetorical high horse from which to harangue everyone not on Team Jesus and from which to push for a repeal of the estate tax. It is, in short, fatuous hyposcrisy.

It is dangerous fatuous hypocrisy, too. Tiller’s murder is the logical and natural consequence of the rhetoric of the Holocaust. We are responsible for the foreseeable consequences of our actions and death is a reasonable consequence of that kind of overheated rhetoric.

(Very Gradual) Change We Can Believe In

22 February 2009

via Mike Rosulek




The Definition of Vice

9 December 2008

A vice is something that you repeatedly do even though you know it will make you unhappier in the long run.

Stop the Bridge

12 November 2008

The Powers-That-Be have all but decided that a bridge needs to cross the river from Gatineau and land on the front doorstep of our neighbourhood. Of all the options that could have been chosen, this one affects (negatively) the most people. Check out the fine purveyors of bridge-related information at Stop the Bridge.

For everything, a limit

25 November 2007

From the Saturday (24 November) Globe & Mail interview with Yann Martel, authour of The Life of Pi:

Michael Posner: Are you Christian by practice?

Yann Martel: My parents were children of Quebec’s Quiet Revolution so I grew up in a completely agnostic household. We were very respectful of religion, but it was anthropological. And I think the reward of religion is harder to get to for young minds. Because they tend to be literal. There’s a certain metaphysical depth to Christ that isn’t acceible to young minds. By the time I got to India, I was just fed up with being reasonable. It’s a waste of life to be nothing but reasonable. If you do that, you strip away everything marvellous in life. It’s why classical music and fiction are suffering. They’re perceived as work, too difficult. Our imaginative lives are shrinking in the West and I don’t think we’re any the better for it. You go to India and the people are so bloody poor and I wouldn’t say everyone is happy there but there isn’t that mean edge of alienation you have here.”

Otonabee Girl

26 September 2007

The naked, sqalling cherub of 1969
is no more.
Nor the C-note kid, coolly sizing up the candy store.
While the lithesome girl of sixteen years,
clad in frank gaze
and borrowed, sexy underwear,
from a fading colour print.

These are but chimera;
the true ghosts;
encoded in the fickle chemistry
of memory.

Sad, these versions of ourselves
lost to the past?
Put out your God-eyes!
is the fully human measure.
Change and loss, growth and novelty
our responsibility
and our birthright.

on the keen-edged knife of the present
rippling under the skin of time
she is flesh.
Mine to have, hold and love.
Better than any ghost
or imagined past.

take up your paddle.
The Otonabee of time awaits.