def fun(str) 。
元音 = ['a'/span>, 'e'/span>, 'i'/span>, 'o'/span>, 'u'/span>, 'A'/span>, 'E'/span>, 'I'/span>, 'O'/span>, 'U'/span>]
if str ==元音。
print ("It is a vowel")
else:
print ("it is not vowel")
fun('a'/span>)
fun('O')
uj5u.com熱心網友回復:
這就是解決方案:
這就是解決方案。
def fun(str) 。
元音 = ['a'/span>, 'e'/span>, 'i'/span>, 'o'/span>, 'u'/span>, 'A'/span>, 'E'/span>, 'I'/span>, 'O'/span>, 'U'/span>]
if str in 聲母。
print ("It is a vowel")
else。
print ("it is not vowel")
fun('a')
fun('O')
uj5u.com熱心網友回復:
不完全是。更像是:
元音= ['a', 'e', 'i', 'o', 'u', 'A', 'E', 'I'/span>, 'O'/span>, 'U']
def is_vowel()。
letter = input()
if letter in 元音。
return("Is a vowel"/span>)
else。
return("is not a vowel")
轉載請註明出處,本文鏈接:https://www.uj5u.com/shujuku/308551.html
標籤:
上一篇:Purr中的地圖功能
下一篇:無法用Python找出元音的數量
