Both. My father was a photographer. Studied in art school before I was born.
When I was about ten years old, he loaded up a camera with film, handed it to me and said, "If you break this, I'll break YOU." He kicked me in the butt and sent me off to take pictures.
He showed me how to develop and print in the darkroom but never had real experience. I just did as Dad said.
I took some photography classes in high school. (That was back in the old days when kids used to learn stuff in school.)
I did a lot of my own developing but very little printing during the time between high school and college.
Second year of college, I took some more photography classes.
Since college, I've learned mostly everything on my own.