19.3.2 ordinal numbers used as adjectives and as nouns
Ordinal numbers can be used as adjectives (the second man) or as a noun (the second). Used as an adjective they describe a noun and used a noun they stand for something else. But that's no problem at all because there is no difference between the adjective and the noun.
adjective: Sai parlare una terza lingua? => Do you speak a third language?
noun: La terza non mi è piacuta. => I didn' t like the third.