Golang : Dealing with backquote
Just a quick tutorial note on how to deal with backquote in Golang or rather a note for myself :P
Wrap the backquote with "
in order to place a backquote inside a fmt.Println()
function.
For example :
package main
import "fmt"
func main() {
fmt.Println("" + "`" + "")
// in between string
fmt.Println(("a " + "`" + " backquote"))
}
Output :
`
a ` backquote
Hope you may find this simple tutorial useful.
By Adam Ng
IF you gain some knowledge or the information here solved your programming problem. Please consider donating to the less fortunate or some charities that you like. Apart from donation, planting trees, volunteering or reducing your carbon footprint will be great too.
Advertisement
Tutorials
+11.9k Golang : Verify token from Google Authenticator App
+5k Golang : Create new color from command line parameters
+3.9k Golang : Constant and variable names in native language
+5.4k Elasticsearch : Shutdown a local node
+25.1k Golang : Find files by name - cross platform example
+8.2k Golang : Eroding and dilating image with OpenCV example
+11.8k Golang : How to get a user home directory path?
+12.6k Golang : convert(cast) string to float value
+12.5k Golang : Get current time
+19.5k Golang : Sort and reverse sort a slice of strings
+6k Golang : alternative to os.Exit() function