python首字母缩写输出
我正在尝试用python输出首字母缩写。我一直在第一行出现语法错误,无法理解。任何帮助都将不胜感激。我是编程新手。
选择 | 换行 | 行号
- #A Program to Display an Acronym
- #By Betty Kaiman
- def acronym_phrase():
- phrase = (input("Give a phrase: ")
- words = phrase.split()
- acronym = ""
- for ch in phrase":
- print ("Character:", ch)
- for words in phrase.split[';'0,13,21,28]
- for ch in phrase.split[0]
- print ("The acronym is", acronym)
- acronym_phrase