Catch up on stories from the past week (and beyond) at the Slashdot story archive


Forgot your password?
For the out-of-band Slashdot experience (mostly headlines), follow us on Twitter, or Facebook. ×

Comment: Re: David Cameron is actually a genuine idiot (Score 1) 256 256

We might need some friendly, Vulcan-like AI to decide stuff for us. It won't stop some people from crying "I'm being oppressed!", but at least we'd have some confidence that it isn't actually trying to oppress anyone (or at least greater confidence than is the case with most humans, that is).

Comment: Re:David Cameron is actually a genuine idiot (Score 1) 256 256

Socialism demands big government

I'm not sure that's the case. Socialism requires state ownership of productive assets (if not all of them, then at least the large ones). But considering the traditional meaning of the word "government", I'm not sure that a state-owned factory counts as government. In other words, would you classify a car production line as a part of the legislative, executive, or judicial branch?

Comment: Re:I can see it now (Score 1) 43 43

Imagine if you would, the ability to reproduce an F1 rocket engine.

That's what Dynetics is trying with the F-1B project... With 8 MN of liftoff thrusts, despite the other projects in the works (the Falcons, Vulcan, the mythical Blue Origin launcher), it could still make for an interesting single-stick launcher.

Comment: Re:You are Doomed (Score 1) 50 50

If you're old enough to remember the micronova [I'm a former DG software engineer and I wrote code for it], you can probably remember the PC "turbo" switch. When IBM realized that PCs were outperforming their mid-range business systems (AS400???), they changed the BIOS to prevent boot if the PC ran too fast. Hence, the turbo switch: Run slow until BIOS is done, push turbo switch to get faster clock speed.

That was IBM's first attempt to control [PC] turf. The second came with the micro channel architecture (MCA). Their proprietary licensing caused clone mfgrs to revolt and form a standards organization that produced the ISA bus. Eventually, IBM lost control of a market it created.

Same thing is happening with MS. Tried too hard to map everything back to Win*, even for mobile. Now, they're late to the party and are open sourcing .NET--but it's too late. Mindshare [among developers] has already headed to Android/IntelliJ/etc.

Comment: Megaharm (Score 1) 1067 1067

System wide setting? Most other programs don't want it. What you want is a function you can call at the start of your program: no_div_by_zero_exceptions_in_this_program().

But, that is a bad idea (tm) because the programming language/system doesn't know the context. That is, what you intend if div-by-zero occurs on a line-by-line basis. That's why you have to have explicit checks:

if (y != 0)
    z = x / y;
    z = ...; // what you want: x, 0, inf, -1, throw exception, abort program, whatever

But, this is just a single check out of the things a program has to check for:
- null pointers
- array bounds
- insane/wrong values (e.g. a person's age shouldn't be a negative number)
- object in wrong state for operation to be performed (e.g. trying to do a database operation when the DB handle isn't locked)
- ...

Also, drawing on the recent Linux raid0 problem [where FS corruption was happening], they had something akin to:
    sector_offset = absolute_byte_position / sector_size;
If sector_size happened to be zero (a programming mistake), silently returning zero here would corrupt the disk/file.

You've been programming for 20 years? Well, junior [I've been programming for 43--sigh], you've still got a lot to learn. And the fact that you didn't see the harm before you posted proves that.

You're using a keyboard! How quaint!