Recent comments in /f/explainlikeimfive

Sloloem t1_iyalbym wrote

The idea that "Goto statement considered harmful" came from an essay by Dijkstra that was published in 1968 during the dawn of computer science.

His basic case was that GOTO was too primitive to have a single easily understood function when seen in code. It tells the machine to arbitrarily move control to a different instruction at a different line of the program but says nothing about why or what's going to be there. Also since you need to physically start reading somewhere else in the code with the context of what's in memory from the previous location in mind it can make programs extremely hard to read and verify, especially in an age before IDEs and debuggers. It allowed for too wide of a gap between the mental model of a static program and a dynamic running process.

He advocated instead for what he called "structured programming" which is really just programming as anyone born after maybe 1964 understands it. Structured programming makes extensive use of this new-fangled idea from the late 50's called "blocks", because someone had to invent the idea of:

if (true thing) {
    doThings();
}
else {
    doOtherThings();
}

at some point.

With blocks that's just the way you write that code with the instructions immediately blocked inside the condition that allows their execution to proceed. With GOTO those lines could be 600 lines away. And without another GOTO to send you back to where you left off, you'll just keep going from wherever you ended up until the program exits or crashes.

GOTO also predates a lot of the looping structures we take for granted in modern programming and while it could be used to implement them, using the actual loops instead carries more meaning and makes your program easier to read, understand, and compile (compilers that translate human-readable source to machine-readable machine code can make certain optimizations in how it feeds instructions into the CPU...as long as it understands what the loop does). So at this point while a lot of the readability issues would be countered by modern tooling, the adoption of more structured ways of writing code and more nuanced looping statements makes goto...kinda pointless.

360

praguepride t1_iyalbdi wrote

If engines are firing or mechanical parts are moving they will likely cause vibrations that will travel through physical connections so you will hear them. But if nothing on the ship is moving or creating noise then there is no ambient sound and you would likely start to become very keenly aware of the noises your body makes. They build perfectly sound proof rooms here and apparently from people who have stayed inside you stsrt noticing your saliva squishing around, the dull thump of your heart beating, gurgles from your stomach and gut etc.

2

Flair_Helper t1_iyal63d wrote

Please read this entire message

Your submission has been removed for the following reason(s):

Questions based on a false premise are not allowed on ELI5. A question based on a false premise is one based on information that may not be true, or may not be the whole truth, and needs that information to stand as a question.

If you would like this removal reviewed, please read the detailed rules first. If you believe this submission was removed erroneously, please use this form and we will review your submission.

1

ToxiClay t1_iyal383 wrote

>But I never understood what people meant when they say a baby was born addicted to crack.

When we speak of addiction, there are two main types.

The psychological addiction or dependence refers to the mental and emotional state where someone feels like they need whatever it is to be normal. We can safely ignore this one in terms of babies, since they don't have well-developed minds to have those responses.

The physical addiction or dependence, however, refers to actual quantifiable changes in the state of the body that makes the body physically require the drug. Addiction to alcohol, for example, causes physical changes in the structure of the brain in order to adapt. Removing alcohol, especially suddenly, throws the body into disarray due to the sudden change in the chemical bath.

This is what is meant when doctors say a baby is "born addicted" to a drug -- their brains have already been changed in the same way as a drug addict's.

6

-WhatCouldGoWrong t1_iyajz7e wrote

homicide is always a crime since its the unlawful kiling of another person, what differs is what can be proven, and what can be prosecuted when it comes to court

​

not sure how its legally defined in other countries but in the U.K. it is to do with intent

​

did the person wait in a bush outside victim's house, with a gun, and jump out and shoot man when he got home from work (predetermined, intent) (murder)

​

or did man get home early from work, walk in on next door neighbour balls deep in his wife (discovered affair), pick up lamp off it's position on bedside table and smash him on the head (in the moment) (manslaughter)

​

some countries the manslaughter ting there could even be argued as a crime of passion and wouldn't even be manslaughter

​

and then there is also conspiracy, where one mans crime becomes every mans crime (for example gangs)

​

you could be sent to prison for murder just for driving a car through the acts of a passenger (for example a shooting drive by, passenger kills man, you were driver, you also are responsible for the crime and therefore cop a murder charge)

1

Phage0070 t1_iyajciz wrote

Your submission has been removed for the following reason(s):

ELI5 is not for straightforward answers or facts - ELI5 is for requesting an explanation of a concept, not a simple straightforward answer.

If you would like this removal reviewed, please read the detailed rules first. If you believe this was removed erroneously, please use this form first. If you believe this was removed erroneously, please use this form and we will review your submission.

1

druppolo t1_iyajbgd wrote

Is effective.

A bear can smell food even if properly packed. But let’s say the smell of the at food is 10 times less, that’s the difference between drawing any bear to you in a radius of 1 km or 10 km.

The math may not be exact but I hope you get e point. If the smell is kept small, you basically alert the bears that are close enough to be encountered anyway.

As most topics, prevention does not guarantee success, but meeting one bear that happens to be close enough every 30 hike you do is way better than meeting a bear every hike.

Most importantly, never feed animals. You teach them human=restaurant. Imagine next time you get invited to a restaurant everyone gets food except you… you get angry, do you? Imagine how angry a bear gets being fooled that way.

1