mirror of
https://github.com/duke-git/lancet.git
synced 2026-02-04 12:52:28 +08:00
19 lines
269 B
Go
19 lines
269 B
Go
package formatter
|
|
|
|
import "fmt"
|
|
|
|
func ExampleComma() {
|
|
result1 := Comma("123", "")
|
|
result2 := Comma("12345", "$")
|
|
result3 := Comma(1234567, "¥")
|
|
|
|
fmt.Println(result1)
|
|
fmt.Println(result2)
|
|
fmt.Println(result3)
|
|
|
|
// Output:
|
|
// 123
|
|
// $12,345
|
|
// ¥1,234,567
|
|
}
|