Please create an account to participate in the Slashdot moderation system

 



Forgot your password?
typodupeerror
×

Comment Re:About that link (Score 1) 358

But why should upper-middle class pay a greater percentage of their earnings toward roads than the lower-middle class?

Marginal income. A lower-middle-class family might have to spend, say, 85% of their post-tax income on basic necessities, whereas an upper-middle-class family might be able to meet those same needs on 60% of their income. Wealthier people have more cash left over after their basic needs are met. That's why we have progressive marginal tax rates.

Do rich people wear out roads faster?

Yes, they do. They take public transit less, and they drive more and bigger cars.

Do the cops spend more or less of their budget year dealing with rich or poor people?

Rich people have a greater expectation of service from the cops than poor people do.

Obama, et al, really do think your money belongs to them first. To be doled out as they see fit.

The only difference between Obama and Bush is that Obama thinks the rich should pay taxes.

Comment Re:What are you guys talking about? (Score 1) 533

"Cut your teeth" is a term from the pre-industrial era, when only master craftsmen could design and build mechanical equipment. The masters worked with entire gear trains, apprentices were put to work polishing the metal plates from which gears were made, and journeymen made the gears. In order to graduate from apprentice to journeyman, you had to design and fabricate your own tooth-cutting bit and make a gear. If it meshed with the gears the established journeymen were making, you qualified.

Comment Re:Maybe not ALL tenets... (Score 1) 794

Excellent response. Using break statements would have the same effect that my GOTO statements have, with non-GOTO syntax.

Using multiple return points in my experience is more trouble than not. It is just another magic "get me the fuck out of here", plus you have to duplicate your cleanup code.

When I'm chasing a bug, tracing the a program is easier when I know a function only exits in one place.

Comment Re:Maybe not ALL tenets... (Score 1) 794

Boolean combinations doesn't really address my need. Most of my functions follow a pattern something like this:

Set the return code to fail.

Check the parameters. If there's anything wrong, just bail and return.

Perform step 1. If it fails, don't bother going any further, just bail, perform necessary cleanup, and return.

If step 1 doesn't fail, then use the results of step 1 to perform step 2. And so on through step N.

Set the return code to success.

Clean up and return.

Without the use of GOTO, the indentation level gets deep in a hurry. With GOTO, you know that at any given point in a function, all the dependencies are successfully met in order to get that far.

You may call it bad coding style; when I was a TA for freshman programming, I know I would have. But in practice, I find it to be a very elegant solution that dramatically improves code readability and debuggability in some cases.

Comment Maybe not ALL tenets... (Score 1) 794

I use GOTO quite often. It is useful for keeping code from getting deeply nested, which in fact can impair code clarity.

Where you might say:

if( OK ) {
... function body ...

}

return;

I would say:

if( NOT_OK ) goto DONE;
... function body ...

DONE:

return;

Now imagine the above example, with 8 or 10 different places where the value has to be tested before proceeding. Without GOTO, your code is indented at various depths across the screen. With it, your code lines up neatly and is easy to scan.

Role Playing (Games)

A History of Rogue 240

blacklily8 writes "Gamasutra has published "The History of Rogue: Have @ You, You Deadly Zs." Despite only the most 'primitive' audiovisuals, Rogue has continued to excite gamers and programmers worldwide, and has been ported, enhanced, and forked now for over two decades. What is it about Wichman and Toy's old UNIX RPG that has sent so many gamers to their deaths in the Dungeons of Doom, desperately seeking the fabled Amulet of Yendor? This article covers the history of the game, including the Epyx failure to make a ton of cash selling it in 1983. It also goes into rogue-like culture and development."

Slashdot Top Deals

"Show me a good loser, and I'll show you a loser." -- Vince Lombardi, football coach

Working...