Want to read Slashdot from your mobile device? Point it at m.slashdot.org and keep reading!

 



Forgot your password?
typodupeerror
×

Comment Re:wow (Score 1) 844

I understood the point of your original reply to mean "moderates of other groups behave the same way too." When I pointed out the extremist position of Islam (and implied that it is quite different as things stand today), you then implicitly accused me of a straw man.

The moderate reaction is unavoidably related to the extremist reaction when that extremist reaction represents a significant percentage of the group. When mobs march the streets, embassies get torched, and people beheaded for expressing an opinion and the moderate reaction is "you should not have offended our Prophet," it is a tacit approval of the extremist reaction.

When someone insults the Pope and the fundamentalists by and large do little more than thump their chests and yell a lot, a moderate reaction of "you should not have offended our Pope" sends a much different message in this context.

Comment Re:wow (Score 5, Interesting) 844

The parent's post might be worded rather harshly and somewhat unfairly, but the general point is valid.

During the Danish cartoon incident, I was quite surprised that the primary reaction of moderate Islam wasn't condemning the violence of their fellow Muslims, but rather insisting that the cartoonist should not have insulted their prophet.

Windows

Vista To XP Upgrade Triples In Price, Now $150 907

ozmanjusri writes "Dell has tripled the charge to upgrade Vista PCs to XP. Under current licensing 'downgrade' agreements, system builders can install XP Pro instead of Vista Business or Vista Ultimate; however, Dell has opted for a surcharge of $150 over the price of Vista for the older but more popular XP Professional operating system. Rob Enderle says the downgrade fees could potentially be disastrous for Microsoft: 'The fix for this should be to focus like lasers on demand generation for Vista but instead Microsoft is focusing aggressively on financial penalties," says Enderle. 'Forcing customers to go someplace they don't want to go by raising prices is a Christmas present for Apple and those that are positioning Linux on the desktop.'"

Comment Re:Adventures in duck-typing (Score 1) 311

What you describe (that names are merely labels attached to objects) is more or less right, but doesn't capture what duck typing is.

Duck typing is summed up neatly by contrasting two principles: LBYL (look before you leap) and EAFP (easier to ask forgiveness than permission). These catchy phrases nicely capture two different methods. Consider these examples (numbered 1 through 4):

def square(value):
.. if type(value) != int:
..... raise ValueError('Argument must be an int')
.. return value**2

def square(value):
.. if isinstance(value, int):
..... raise ValueError('Argument must be an int')
.. return value**2

def square(value):
.. try:
..... return value**2
.. except TypeError:
..... raise ValueError('Invalid value passed')

def square(value):
.. return value**2

(Sorry about the prepended dots, but Slashdot's ecode tag is lame.

If you're used to statically typed languages, you may gravitate to the first two examples, but this is unpythonic. This tests that the type of the value passed is what you expect, and in doing so, prevents duck typing, because you can't pass it an object that acts like an int. (The second one is slightly better than the first, in that it will allow other objects so long as they are subclassed from int.)

The third example is better still, but why bother catching the exception at all? In doing so, you're passing less information in the exception than if you'd just done nothing at all, which is what example 4 does. Example 4 is pythonic: it allows duck typing (anything that supports __pow__ can be passed), and if the value is invalid, the TypeError exception automatically raised will be informative.

Comment Re:HDMI and Hollywood (Score 1) 603

Out of curiosity, what was the source your friend was using? If it was a Blu-ray player, that could be consistent with what I've heard. (That Blu-ray licensing terms rather than HDCP may necessitate downscaling on analog outputs. But I've not read anything authoritative on that.) But if it's a cable terminal, I'd be curious to know what cable provider was used.

I know that the DCT for my cable provider (Rogers) doesn't downscale over component, so I capture that way. And for Blu-ray, AnyDVDHD has been a worthwhile purchase. :)

Comment Re:28 lines in Prolog :-) (Score 3, Insightful) 311

in a Python doc comment, I'd be a rich guy. What is a foo exactly? A class? A tuple? A list of tuples of classes? Or worse, any of the above?

This is certainly one of the practical drawbacks of duck-typing. But name-based polymorphism is exceedingly powerful, and with great power comes great responsibility. (Namely, to document one's arguments and return values properly.)

Comment Re:HDMI and Hollywood (Score 1) 603

My understanding with HDCP licenses was that downscaling is only required when the ICT flag is enabled, and I didn't think the ICT flag was being used yet. (I seem to recall some agreement not to use it for some years, but maybe "some years" have passed.)

Blu-ray itself might be a different matter. I vaguely remember reading about Blu-ray licensing requiring downscaling through all analog outputs.

In any case, I'm very skeptical about your original claim that the TV (as opposed to the source) was downscaling HD signals coming in over component. I'm going to play the "citation needed" card on that one.

Comment Re:Because Americans are a Polity, not a Volk (Score 1) 622

This Canadian doesn't consider himself very patriotic. I see my relationship with my country primary as a business relationship: I provide payment in the form of taxes and agree to follow a certain set of laws (which more or less overlap well with my moral views anyway), and in exchange my country provides me infrastructure, social services, and a generally good quality of life.

If my country begins to piss me off and it's clear our differences become irreconcilable, I would take my business elsewhere, provided better options existed. (If I were American, for example, I'd have relocated to Canada some years ago.) To me, patriotism smells disturbingly like religion, with all the same blind allegiances and childhood indoctrination. It also provides one more vehicle for group-think.

That's not to say I'm not proud of Canada. I think we do a lot of things fairly well, relative to other countries. It's just not something I would put on the same level of what I consider patriotism.

Slashdot Top Deals

HELP!!!! I'm being held prisoner in /usr/games/lib!

Working...