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

 



Forgot your password?
typodupeerror

Comment Re:Else ifs - yuck (Score 2) 399

To expand upon your final point: The real reason to use switch vs else-if is in what you communicate to other programmers. Switch communicates that you're evaluating exactly one variable/operation. Else-if towers can mix and match the evaluation criteria. Programmers who choose an else-if tower for evaluating the same variable all the way through are just inviting trouble in the future, when someone comes along and adds an additional clause to one of the evaluations and screws the whole thing up. Oh also, some compilers have a maximum number of else-if conditions. I worked at a company that created a huge else-if tower which eventually grew too large and broke MSFT's cl. We quickly rewrote the code as a hashtable (which is what it should have been anyway).

Comment Re:Unconstitutional (Score 2) 332

The "they" you're talking about - Congress and the President - don't have the Constitutional power to make it legal. It's illegal by virtue of the provisions of a Constitutional Amendment, meaning only another amendment can change that. The "they" in question just put on a good show for the rabble while continuing to serve their masters, rather than protect and defend the Constitution as they swore to do.

Comment Re:Buffer overflow (Score 3, Interesting) 611

For the record, this has been true for a couple of decades. There are only a small number of cases where writing assembly can produce better code, and most of those have to do with application-level semantics that can harness register data to get better results. One example of this is bignum math, where it's frequently useful to sample the carry flag to optimize sequential addition. Even here, however, this effect is usually achieved by compiling the C code to assembly and then hand-optimizing only the smallest portion of the code to use the carry/borrow flag.

Comment Re:No. (Score 1) 1486

Sadly, I think you're missing the point. Science isn't just another thing to be "believed in" - it's a system by which hypotheses can be accepted or rejected. So, yes, even when I don't have all of the knowledge to understand the specific details, I am confident that the conclusions that have been drawn to date in any area of scientific thought are not contradicted by the data at hand. Said another way, science liberates me from having to prove everything in every instant, because it lets me put my faith in the process, not the conclusions themselves. In stark contrast, religion says that there is no process for verification, and that the central tenets cannot be questioned or validated, and everything else builds on that.

Slashdot Top Deals

A boss with no humor is like a job that's no fun.

Working...