Ordinals for All Numeric TypesBy : Types of system software
This Snippet will extend all numerical types with a method for returning the English ordinal, i.e. 1st, 2nd, 3rd, 4th, etc. Note that floating-point types will suffer an implicit integer coercion without rounding. The method ...