TITLE: Usage of set theory in undergraduate studies
QUESTION [13 upvotes]: I would like to ask my colleagues their thought on good practices concerning
set theorical framework in undergraduate studies. For example, have there been any attempt  to use another mathematical formalism, such as ETCS? (for research issues,
see this question).
While most, if not all, of our mathematics are thought, done, written using set theory, our younger students seem to struggle with these concepts. Some can well put a $4\times 6$ matrix in row reduced echelon form but plainly do not understand the meaning of a question like "If $A,B$ are two square matrices of size~$n$, prove that $\ker(AB)$ contains $\ker(B)$." The difficulties with $\varepsilon,\delta$ definition of limits may be of a similar nature.
In fact, one may argue that all set theoretical concepts presently are more or less eliminated from the lower levels of mathematical education. One may even argue that it should be so. I remember that each one of the first years of middle school (from 6th grade on, the French and US systems coincide here!) taught me one new definition in set theory; sets and mappings at the age of 11, then equivalence relations, then sets of equivalence classes (to define vectors)...  And a few years later, students are taught quotient groups like $\mathbf Z/n\mathbf Z$ as sets of equivalence classes, a definition which they of course take litteraly. 
While Set theory is very useful to formalize things, at least once you're used to it,
it is true that it allows stupid questions, requires abuses of notations (so that one does not distinguish between the $1$ of $\mathbf Z$ with the $1$ of $\mathbf R$,
not forgetting thoses of $\mathbf Q$ and $\mathbf C$). In some sense, modern mathematicians, especially algebraists, speak sets but think categories.
This may be related with the fact that the precise definition of the axioms of set theory (ZFC, say) are not so well known among mathematicians, and even not really taught (for example, no mention of the replacement axiom in my own mathematical education). In contrast, a more recent book like Terence Tao's Analysis begins with a precise exposition of these axioms, up to this replacement axiom.
I can't really make my mind between one attitude and the opposite.
So what do you think?

REPLY [6 votes]: As a set theorist, I feel some obligation to offer an answer here.  First, the difficulties students may have in proving set theoretic containments like the one you mention above or in constructing $\epsilon$-$\delta$ proofs is not a matter of them struggling with set theory but rather of them struggling with something new: constructing a proof.  In the case of $\epsilon$-$\delta$ proofs, a large part of this difficulty is in understanding quantifiers and how they work (for instance "for all ... exists ..." is not the same as "exists ... for all ...".  This is because math is not a trivial subject to learn and some difficulty is required as the students minds stretch and grow.
Surely there is no way around this.
That really has nothing to do with set theory so far.  In spite of a common misconception, set theorists do no actually care how it is that ordered pairs are defined.  Or how exactly one codes the notion of a function.  Set theory is not in competition with category theory, in spite of what category theory thinks.  A very good analogy is provided by computer science: set theory is machine language (or maybe better: a low level language like C) and category theory is object oriented programming.  While object oriented programming may provide a useful way of thinking about how to write a program, there still needs to be a machine language for the computer to run on.  Moreover, there are occasionally things for which it is just better (or even necessary) to code in a low level language.
Set theory provides an exact standard by which to discuss questions like "is there a subset of the real line which is uncountable but not of cardinality $|\mathbb{R}|$" (Hilbert's First Problem) or, maybe better,
"is there an almost free, non free group?" (Whitehead's problem) or "If $h$ is a homomorphism
a commutative Banach algebra into $C[0,1]$, is $h$ continuous?" (the negation being Kaplanski's conjecture).  With the exception of the first question, these were asked, to my knowledge at least, without any thought that there was a foundational issue involved.  Surely these are questions which could reasonably be asked regardless of how one sets up their foundations.
To my knowledge category theory has never resolved these questions; set theory has in as satisfactory a manner possible (or at least until we adopt a more complete set of axioms).  Now, one can argue at length about whether such questions are asked in poor taste or whether we should allow them to be asked at all.  Readers interested in the question of "why care about set theory" should take a look at this (which might have been titled "why care about the uncountable").