\cleardoublepage \chapter{Preliminaries} \ccHtmlNoClassLinks \begin{ccClassTemplate}{pair} \ccSection{Pair} \ccDefinition A struct \ccClassName\ is a heterogeneous pair of values. Its data members are \ccStyle{first} and \ccStyle{second}. \ccInclude{pair} \ccCreation \ccCreationVariable{p} \ccConstructor{pair(const T1& x, const T2& y);} {Introduces a pair.} \ccOperations \ccGlobalFunction{template bool operator==(const pair &p, const pair &p1) const;} {Test for equality: Two pairs are equal, iff their data members are equal.} \ccGlobalFunction{template bool operator<(const pair &p, const pair &p1) const;} {Lexicographical comparison of two pairs.} \ccExample \begin{cprog} Employee irene("Irene", "Eneri"); Employee leo("Leonard", "Eneri"); typedef int Social_security_number; pair p1(7812, irene), p2(5555, leo); assert( p1.first == 7812 ); assert( p2.second == leo ); \end{cprog} \end{ccClassTemplate}