Sometimes it takes very little for us to learn that something is bad for us. E.g. touching a hot stove. One touch of the stove at 2 or 3 years old creates a lifetime wariness of hot metal.
Then there are the harmful things which don't ellicit an immediate pain reaction. E.g. Smoking.
Which is the more dangerous of the two?