Golang string to int

02 January, 2017

The built in 'strconv' package contains a function named 'Atoi' (ASCII to integer). Which is just a wrapper for the 'ParseInt' function.

Golang mgo create objectid from a hexadecimal string example

19 May, 2016

Storing a string that holds the hexadecimal string of a objectID is done by using the bson package with function 'objectIdHex()'.

Golang hash sum and checksum to string tutorial and examples

17 April, 2016

The output of the function "hash.Sum()" is generated in byte code, and the output of "Checksum()" is a unsigned integer.

Home