initial commit
This commit is contained in:
16
cmd/test/main.go
Normal file
16
cmd/test/main.go
Normal file
@@ -0,0 +1,16 @@
|
||||
package main
|
||||
|
||||
import (
|
||||
"fmt"
|
||||
"net"
|
||||
)
|
||||
|
||||
func main() {
|
||||
// ip := net.ParseIP("192.168.168.12")
|
||||
ip := net.ParseIP("ghallsda")
|
||||
// ip := net.ParseIP("::1")
|
||||
fmt.Println(ip.To4(), ip.To16())
|
||||
fmt.Println(len(ip.To4()))
|
||||
|
||||
fmt.Println()
|
||||
}
|
||||
Reference in New Issue
Block a user