diff options
-rw-r--r-- | lib/str.go | 9 |
1 files changed, 9 insertions, 0 deletions
@@ -90,3 +90,12 @@ func NumToChar(n int64) byte { return 0 } +func NumToStr(n int64) string { + s := "" + for n != 0 { + s = string(NumToChar(n%10)) + s + n /= 10 + } + return s +} + |