Advertisement
Mofeoluwa

Untitled

Feb 22nd, 2020
111
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Python 0.32 KB | None | 0 0
  1. empty = []
  2. active = 'True'
  3. favorite_numbers = [1,2,3,4,5]
  4. colors = ['red','green','blue']
  5. def is_long(list): #define a function named is_long with argument list
  6.     s = "True" if len(list) > 5 else "False" #a list comprehension to print True if the length of the list is more than 5 and print false if otherwise
  7.     print(s)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement