Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- package main
- import (
- "encoding/hex"
- "fmt"
- )
- func main() {
- s := "hello\nworld"
- fmt.Printf("%s\n", hex.EncodeToString([]byte(s)))
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement