65
Go Base64 Encoding
we can encode String and url in Go. Go has Encoder which takes byte array and convert into string encoding.
The Decoder takes the encoded value and covert it to the original string.
Go Base64 Example
Output:
value to be encode [email protected][email protected]#$%^&*() Encoden value: SmF2YVRwb2ludEAxMjM0NSFAIyQlXiYqKCk= Value to be decode SmF2YVRwb2ludEAxMjM0NSFAIyQlXiYqKCk=Decoded value [email protected][email protected]#$%^&*() url to be encode https://golang.org/ref/spec Encoded url aHR0cHM6Ly9nb2xhbmcub3JnL3JlZi9zcGVj value to be decode aHR0cHM6Ly9nb2xhbmcub3JnL3JlZi9zcGVj Decoded value https://golang.org/ref/spec Process finished with exit code 0
Next TopicGo Random Number