acronym1 s = newstring s
where
newstring [] = []
newstring [h] = []
newstring (h : t)
| h == ' ' = ds (myHead t : (newstring t))
| otherwise = newstring t
我目前正在做首字母缩略词,但是
你可以简单地acronym1
加上你的前缀:
acronym1 s = newstring ("_ " ++ s)
或者,您可以重写newstring
以采用isFirstLetterOfWord
您true
在第一次调用时和空格之后设置的布尔参数,或者false
其他方式。
本文收集自互联网,转载请注明来源。
如有侵权,请联系 [email protected] 删除。
我来说两句