Follow Slashdot stories on Twitter

 



Forgot your password?
typodupeerror

Slashdot videos: Now with more Slashdot!

  • View

  • Discuss

  • Share

We've improved Slashdot's video section; now you can view our video interviews, product close-ups and site visits with all the usual Slashdot options to comment, share, etc. No more walled garden! It's a work in progress -- we hope you'll check it out (Learn more about the recent updates).

×

Comment: Re:What's Unique To Goto? (Score 1) 677

by Longjmp (#49040357) Attached to: Empirical Study On How C Devs Use Goto In Practice Says "Not Harmful"
Your example is just bad and exactly a reason why some people should avoid goto by all means.

First, a 'return' between allocating memory and cleaning up? Hello memory leaks!
Second, if you have a more complex program flow which allocates more 'bufs', do you really want 15 different gotos and labels)?
Do you, after 6 months, remember which 'buf' is allocated where and make changes? Even more so, do you think someone else finds your code easy to understand?

I don't mind gotos at all if used properly (e.g., cleanup) at all, so try this instead:

(allocate memory, etc)

if (shit_happens) goto cleanup;
br> cleanup:
if (buf1) free( buf1);
if (buf2) free(buf2);
etc...

Comment: Re:Jesus, we're fucked. (Score 5, Interesting) 351

by Longjmp (#48898199) Attached to: Americans Support Mandatory Labeling of Food That Contains DNA

80%?! 80% of Americans are unfamiliar with one of, if not *the* most fundamental concepts of biology?

Recently I explained to a friend why you shouldn't freeze some fruit, because the water will break the cells and the fruit will become mushy.
Her reply: "What are cells?"
After a few moments of baffled silence, I tried to explain how cells are the base "Lego bricks" for all life.
Next she asked "So if you eat cells, it's good for you?"

Comment: Re:Entropy underlies all? (Score 1) 197

by Longjmp (#48636159) Attached to: Quantum Physics Just Got Less Complicated

... It just means we probably can't tell if we're in a simulation because we're defining reality as simulate-able.

Our universe being a simulation is certainly an interesting idea.
However I somewhat cringe at the thought of myself running on the equivalent of a 14 yo alien's PC while his mother yells "Come up for dinner now or I'll come town and pull the plug!"

Comment: Re:10 Year Anniversary (Score 1) 51

by Longjmp (#46066443) Attached to: 'Opportunity' Celebrates 10 Year Anniversary Roving Mars
It is a widespread misconception that Inuit have dozens of names for snow. They don't have significantly more words than plain English.
However their language allows to combine words into a new noun, examples in English would probably work like this:

"snow on ground" -> "groundsnow"
"falling snow" -> "fallsnow"

Comment: Re:Spiked tyres and featered tread and higher sili (Score 1) 139

by Longjmp (#45804939) Attached to: Wisconsin Begins Using Cheese To De-Ice Roads
Better tyres yes, spiked tyres depends.
They make sense in areas/countries with low population density and snow covered roads.
On mostly ice/snow free streets they wear down any pavement quite fast, resulting in street repair costs magnitudes higher than the initial savings during winter.
That and they are really shitty compared to normal tyres when you brake.

Comment: Re:Feeling justified in eschewing e-books (Score 1) 120

by Longjmp (#45785039) Attached to: E-Books That Read You

Would you like to participate in an experiment? Good!
On the count of three, throw your e-reader at the wall. I'll throw a printed book at the wall. Does yours still work? Mine does! [...]

I'm deeply impressed how you managed to get your post as a written letter delivered to slashdot via snail-mail. and have them type it in for you ;)

Comment: Re:I have to laugh over the rolling vs howling... (Score 4, Funny) 219

by Longjmp (#45679535) Attached to: Wikipedia's Lamest Edit Wars

* I'm going to go out on a limb and say that I think that the pronunciation change is more noticeable in US media.

Well, the British are famous for some pronunciations too, especially when it comes to town names.
Just look at the nice little town of Littlelancfordupstratdoushire, pronounced "oi".

"Well, if you can't believe what you read in a comic book, what *can* you believe?!" -- Bullwinkle J. Moose

Working...