package main
import (
"fmt"
"strings"
"unicode/utf8"
)
func countRunes(words []string) []rune {
runes := make([]rune, len(words))
for index, runeValue := range words {
runes[index] = rune(utf8.RuneCountInString(runeValue))
}
return runes
}
func main() {
word := "Now I need a drink, alcoholic of course, after the heavy lectures involving quantum mechanics."
word = strings.Replace(word, ",", "", -1)
word = strings.Replace(word, ".", "", -1)
words := strings.Split(word, " ")
fmt.Println(countRunes(words))
}