Become a fan of Slashdot on Facebook

 



Forgot your password?
typodupeerror
Check out the new SourceForge HTML5 internet speed test! No Flash necessary and runs on all devices. ×

Comment Re:Curly braces = good. Indents = bad. (Score 1) 173

I don't know about everyone else, but I find it *immensely* helpful to write debugging statements without indentation. This makes it so that they stand out from the normal statements among which the debugging statements are inserted. This is the reason I won't even consider using Python.

Just stick "# XXX" comments around your debug code. Many editors automatically highlight XXX so prominently that it's just as easy to spot as unindented code.

Now, all you Python-indentation-style lovers, consider how you would code this kind of Go initializer:
        arr := [][]int{{1,2,3},{4,5,6}}
(This declares the variable 'arr' as a slice of slices of ints and initializes the variable.)

You mean, like:
arr = [[1,2,3][4,5,6]]
What's the problem?

Comment Re:Other than Brother... (Score 4, Insightful) 387

About 5 years ago, my Brother laser printer said it was low, so I taped over the window. A couple of years later, I did get off my lazy ass and ordered a new cartridge so that I wouldn't interrupt my workflow. However, the original cartridge that came with the printer still hasn't run out. I have no idea when and if I'll ever need to install the new cartridge.

As you can guess, I don't do very much printing. However, the "low toner" light probably started blinking after printing only about 1/4 of the total number of pages I've gotten out of it so far.

This whole episode does reinforce the decision I made before buying the laser printer: I will never, ever buy another inkjet printer as long as I live. Those cartridges seem to dry up, clog and die even if I don't use them. I got sick of spending $30 on a set of cartridges, only to get a hundred pages out of them before they became useless from age. At least laser printer toner seems to have an almost unlimited lifespan.

Comment Re:cable is not over the air waves (Score 1) 149

If a cable company puts some wire down, they ought to be able to do whatever they want with it as it does not interfere with other devices.

Before we implement your corporate utopia, first we need to rescind all property easements.

Then the cable companies can negotiate with each individual land owner to determine an appropriate agreed rental fee for allowing those wires in each parcel of property. If they can't come to an agreement with any particular owner, they can make deals with other land owners and re-route their cables.

Once all of that is complete, then they can completely deregulate cable.

Comment Re:Decimal Numbers? (Score 1) 427

Accountants always go for arbitrary precision with accuracy settings twice as far out as precision and decimals only ever actually evaluated when they are to be presented to a human.

There's the whole problem with your smug position.

Accountants typically represent intermediate results to humans at many points in their algorithms. At each of these steps they make gross roundoff errors, but they make sure that all of the rounded off numbers add up neatly at the end. All of your vaunted precision and lazy evaluation has just been made irrelevant.

Accountants shrug it off and declare it to be the correct answer, when in many cases appropriately designed algorithms using plain floating point would have come out closer to the actual truth.

Slashdot Top Deals

Machines that have broken down will work perfectly when the repairman arrives.

Working...