Advertisement
Guest User

Untitled

a guest
Feb 22nd, 2020
113
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Python 0.27 KB | None | 0 0
  1. '''function to check if a string is in a given list(lst)
  2. and if the string has more than four characters'''
  3. def long_word_in_collection(lst,string):
  4.     if (string in lst) and (len(string) > 4):
  5.         return True
  6.     else:
  7.         return False
  8. long_word_in_collection()
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement