package
module
Version:
v0.0.0-...-85c975e
Opens a new window with list of versions in this module.
Published: Feb 21, 2015
License: MIT
Opens a new window with license information.
Imports: 2
Opens a new window with list of imports.
Imported by: 3
Opens a new window with list of known importers.
README
¶
syllables
A syllable is a unit of organization for a sequence of speech sounds.
Programmatically count number of syllables in word, some specific words requires more attention and might vary between +/-1 syllable.
Benchmark
'Longest' word has 189,819 letters, takes three hours to pronounce and it takes 1/3 of seconds to process
Read more: http://www.digitalspy.co.uk/fun/news/a444700/longest-word-has-189819-letters-takes-three-hours-to-pronounce.html#ixzz3SITIl2nM
Function |
operations |
ns/op |
sec/op |
BenchmarkCountSyllables |
20000 |
97600 ns/op |
9.76e-5 sec/op |
BenchmarkCountSyllables (Longest word 189,819 char) |
5 |
318114133 ns/op |
0.318114133 sec/op |
Documentation
¶
func CountSyllables(word []byte) (matches int)
CountSyllables -
func CountSyllablesInText(text [][]byte) (count int)
CountSyllablesInText - count syllables in text
Source Files
¶
Click to show internal directories.
Click to hide internal directories.