Last active
June 14, 2020 10:24
-
-
Save yasukotelin/ff85a84a68920457d6bfde1384d4a961 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
func convStringsToInts(strings []string) []int { | |
result := make([]int, len(strings)) | |
for i, v := range strings { | |
num, _ := strconv.Atoi(v) | |
result[i] = num | |
} | |
return result | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var scanner = bufio.NewScanner(os.Stdin) | |
func readline() string { | |
scanner.Scan() | |
return scanner.Text() | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment