Skip to content

Instantly share code, notes, and snippets.

Created May 29, 2018 05:45
What would you like to do?
GoLang : String to Int Conversion
package main
import (
func main() {
str := "12345"
// String to Int conversation => strconv.Atoi function return integer with error if any.
// Atoi means "A" String to "i" integer
intI, err := strconv.Atoi(str)
if err == nil{
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment