packagehumanizeimport"strconv"// Ordinal gives you the input number in a rank/ordinal format.//// Ordinal(3) -> 3rdfuncOrdinal(xint)string{suffix:="th"switchx%10{case1:ifx%100!=11{suffix="st"}case2:ifx%100!=12{suffix="nd"}case3:ifx%100!=13{suffix="rd"}}returnstrconv.Itoa(x)+suffix}