From the book: General Topology,from Schaum's Outline Series i quote from page 32 the part that solves your problem:
" A set A is called equivalent to a set B,written A~B,if there exists a function f: A --->B which is one to one and onto.The function f is then said to define a one to one correspondence between the set A and B.
A set is finite iff it is empty or equivalent to {1,2,.........,n} for some nεN,otherwise it is said to be infinite.
Clearly two finite sets are equivalent iff they contain the same number of elements.
According to the above quotation ,since S is equivalent to T ,THEY have the same number of elements,and they have the same cardinality n