چاپ بزرگترین کلمه در متن ، چاپ بزرگترین کلمه در لیست ، چاپ بزرگترین کلمه در لیست در پایتون
چهارشنبه, ۲۸ آبان ۱۳۹۹، ۱۱:۴۲ ب.ظ
چاپ بزرگترین کلمه در متن
چاپ بزرگترین کلمه در لیست
#786
#Author:Bisavad
#@GameOverBlog
#Return Big Word in Text
def big(list):
b=list[0]
for word in list:
if(len(word)>len(b)):
b=word
return b
text="salam chetori aziz az gameoverblog che khabar"
list=text.split()#['salam', 'chetori', 'aziz', 'az', 'gameoverblog', 'che', 'khabar']
print(big(list))
۹۹/۰۸/۲۸