I know the original question title "what is the foundation of mathematics really?" seems pretty bad, or extremely bad, since it's really a huge question to answer. And I totally accept the fact that someone is going to disapprove this question.
But I have to ask this question anyway, the curiosity, or more kind of like pain, is killing me since it really has been bothering me for a very long period of time.
What is the foundation of mathematics really? Or the other way to state this question is like how those people lived in the past studied mathematics really?
I mean come on, I know nowadays people start to learn math from their elementary school doing simple things like addition or subtraction that sort of Arithmetics stuff, and as they move to middle school or high school, they start to learn geometry, or pre-calculus.
But in my perspective, these contents, or this path of learning math, is purely just a highly condensed abstraction that those people in education field designed that way. I have high confidence to assert that this can't be the way how people in the past learned math. By saying people in the past, I am really talking about peole in the past, like two or three hundred years ago. Moreover, to the very beginning of human kind.
I have done some researches on my own, and it seems like the foundation of modern mathematics is Euclid's elements, this reference is pretty much the one that I can find that looks like the very beginning of math to me. I am wondering if someone can recommend some references like Euclid's elements this sort of "very-beginning-of-math" to me.